Re: SQL: How to substract 1 day from a daytime field ?
Posted in 2000
Oliver
How about:
update TABLE set dttermination = dttermination - interval(1) day to day
where idTABLE =1;OR
update TABLE set dttermination = dttermination - interval(1) day to day
where idTABLE =1;
HTH
Sujit
Oliver Thinnes <oliver_thinnes7845@my-deja.com> on 01/03/2000 06:35:41 AM
Please respond to Oliver Thinnes <oliver_thinnes7845@my-deja.com>
To: informix-list@iiug.org
cc: (bcc: Sujit Pal)
Subject: SQL: How to substract 1 day from a daytime field ?
Hallo.
We're running Informix Online Dynamic Server 7.2 on Win NT 4.0.
I was not able to substract 1 day from a daytime ('dttermination')
field. For
example the value is "01.11.1999" and one day should be subtracted. The
result is "31.10.1999".
Trying the following does not work.
update TABLE set dttermination = extend (dttermination, day to second) -datetime (1) day to day where idTABLE =1;
OR
update TABLE set dttermination = extend (dttermination, day to day ) -datetime (1) day to day where idTABLE =1;
This gives the error message
General SQL error: It is not possible to convert between the specified
types.
Can anyone help me?
Thank you in advance.
Sent via Deja.com http://www.deja.com/
Before you buy.