timestamp arithmetic

If you have questions or if you want to share your opinion about Aware IM post your message on this forum
Post Reply
tkilshaw
Posts: 170
Joined: Thu Jan 19, 2006 11:33 pm
Location: Western Canada
Contact:

timestamp arithmetic

Post by tkilshaw »

Could not find this in the User Manual.

How can I add a day to the value of an existing timestamp.

Adding 1 to a date adds a day to it, but that does not work with timestamps. Looks like I need to multiply the number of days by 24 before adding them.

But how are minutes added?

thanks,

Terry
aware_support2
Posts: 595
Joined: Sun Apr 24, 2005 2:22 am
Contact:

Post by aware_support2 »

Terry,

Adding 1 to a timestamp attribute will increase its value by one hour. So you are right, you need to add 24 to a timestamp attribute to increase its value by a day.

It is also possible to add a value of type Duration to a Timestamp. We will be implementing a function shortly to specify an arbitrary duration value including seconds, minutes, hours, etc. This function will make it possible to change a timestamp value by any desired time interval.
Aware IM Support Team
Post Reply