Home » Developer & Programmer » Reports & Discoverer » date (disc 10.1.2)
date [message #310860] Wed, 02 April 2008 12:16 Go to next message
aarti81
Messages: 235
Registered: December 2007
Location: USA
Senior Member
Hi
I have a report in which you have a field called " selection date". My question is how to get the records " where the selection date is 12 months less than the present date". Please any advice is greatly appreciated.


Thanks
Re: date [message #310893 is a reply to message #310860] Wed, 02 April 2008 14:08 Go to previous message
Littlefoot
Messages: 21813
Registered: June 2005
Location: Croatia, Europe
Senior Member
Account Moderator
Use the ADD_MONTHS function, such as
SELECT * 
FROM your_table
WHERE selection_date >= ADD_MONTHS(sysdate, -12);
Previous Topic: Sequence Number
Next Topic: Losing records
Goto Forum:
  


Current Time: Wed Jul 03 12:02:18 CDT 2024