|
RSS Feed - WebSphere MQ Support
|
RSS Feed - Message Broker Support
|
 |
|
Numeric operation with TIME variables |
« View previous topic :: View next topic » |
Author |
Message
|
kash3338 |
Posted: Tue Jun 16, 2009 6:59 pm Post subject: Numeric operation with TIME variables |
|
|
Shaman
Joined: 08 Feb 2009 Posts: 709 Location: Chennai, India
|
Hi,
I have a scenario where in i have to add certain minutes with current time and store the result in new TIME variable. How do i do this?
As per documentation, the code is as follows,
TIMESTAMP '1999-12-31 23:59:59' + INTERVAL '1' SECOND
Here TIMESTAMP for me is CURRENT_TIME and INTERVAL is dynamic, that is i have the value to be added in an INTEGER variable. How do i acheive adding that value with CURRENT_TIME? |
|
Back to top |
|
 |
MQEnthu |
Posted: Tue Jun 16, 2009 8:22 pm Post subject: |
|
|
 Partisan
Joined: 06 Oct 2008 Posts: 329 Location: India
|
CAST the integer to appropriate INTERVAL (YEAR, Month, Dat, Hour, Minute ort Second....etc) and do the + operation with the current time stamp. _________________ -----------------------------------------------
It is good to remember the past,
but don't let past capture your future |
|
Back to top |
|
 |
|
|
 |
|
Page 1 of 1 |
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|
|
|