Translating with DrWatson… this can take a few seconds the first time.
This is a genuine, complex translation. DrWatson protects commands, error codes, and log output while naturally translating the surrounding text. It’s translated once and saved.
Bill Hamilton — — source: Usenet: comp.databases.informix
GlacierI would like to select into a temp table the number of days between 2
dates,
but that gives an INTERVAL type.
Is there anyway to get that as an INT? (in IDS 7.31)
I suppose one could use the month,day,year functions.
Is that the only way?
sending to informix-list
↪ replying to Bill Hamilton
John Carlson — — source: Usenet: comp.databases.informix
On Fri, 22 Aug 2003 10:04:27 -0500, "Bill Hamilton" <bham@finsco.com>
wrote:
>
>GlacierI would like to select into a temp table the number of days between 2
>dates,
>but that gives an INTERVAL type.
>Is there anyway to get that as an INT? (in IDS 7.31)
>
>I suppose one could use the month,day,year functions.
>Is that the only way?
>
Strange . . . . .
date1=9/9/03
date2=9/13/03
both are defined as date
select (date2-date1)
from jctmp1
returns: 4
those two dates that you mentioned . . . . are they datetime instead
of date?
perhaps this sql could help:
select date1 - date2
from table
hth
danny
"Bill Hamilton" <bham@finsco.com> wrote in message
news:bi5btn$1rj$1@terabinaries.xmission.com...
>
> GlacierI would like to select into a temp table the number of days between
2
> dates,
> but that gives an INTERVAL type.
> Is there anyway to get that as an INT? (in IDS 7.31)
>
> I suppose one could use the month,day,year functions.
> Is that the only way?
>
> sending to informix-list
We use strictly necessary cookies to make this site work. With your
consent we’d also use optional cookies for analytics and marketing. You can accept all,
reject all, or choose. Read our Cookie Policy.