Is there a way to write a sql statement so that it returns the date difference in days?
More specifically, say I have a table containing a field whose datatype is 'date'. How can I retrieve the date difference in days between a given row in this field and the sysdate?
For instance, if a value in this column is 01-01-2005 and today (sysdate) is 01-04-2005, I want the result is returned as 3 ( the datetime difference in days).
Thanks for you help.
More specifically, say I have a table containing a field whose datatype is 'date'. How can I retrieve the date difference in days between a given row in this field and the sysdate?
For instance, if a value in this column is 01-01-2005 and today (sysdate) is 01-04-2005, I want the result is returned as 3 ( the datetime difference in days).
Thanks for you help.