Thread: Use of 'interval'

Use of 'interval'

From
Tom Allison
Date:
I'm digging throught the data types and am trying to understand how to
utilize the interval data type.

I'm thinking I can use these values to add to another date field...

Can someone give a simplified example of how I might use this?

Re: Use of 'interval'

From
Gaetano Mendola
Date:
Tom Allison wrote:
> I'm digging throught the data types and am trying to understand how to
> utilize the interval data type.
>
> I'm thinking I can use these values to add to another date field...

just add them:  timestamp + interval = timestamp


Regards
Gaetano Mendola


Re: Use of 'interval'

From
Mage
Date:
Tom Allison wrote:

>
>
> Can someone give a simplified example of how I might use this?

select '2004.12.31. 13:57:42'::timestamp + '3days 52hours';

       Mage