DATE or is it DAY?
DATE or is it DAY?
(OP)
Hello,
I am extremely new to Informix, so forgive me if my question is the most stupid one you people have had for a long time.
I am looking for a way to write 'yesterday'.
Suppose I have this querry: select * from TABLE where row_date='yesterday'. How do I write 'yesterday? I have tried DAY-1, DATE-1 but that does not work. Can someody point me in the right direction?
I am extremely new to Informix, so forgive me if my question is the most stupid one you people have had for a long time.
I am looking for a way to write 'yesterday'.
Suppose I have this querry: select * from TABLE where row_date='yesterday'. How do I write 'yesterday? I have tried DAY-1, DATE-1 but that does not work. Can someody point me in the right direction?
RE: DATE or is it DAY?
select whatever
from table
where datumsfeld=today-1;
RE: DATE or is it DAY?
RE: DATE or is it DAY?
RE: DATE or is it DAY?
Yes. Use the internal Informix month function. This command:
select * from table where month(datumsfeld) = 3
gets all data from 'table' where the 'datumsfeld' date column is march. There's also corresponding day and year functions.
Regards,
Ed
Schaefer
RE: DATE or is it DAY?