Click to See Complete Forum and Search --> : get last records in oracle


shettykiran
March 14th, 2005, 04:44 AM
Hi,
I want records which are inserted in last one hour. As i have column called create_stamp which takes a system time for every record. What is possible solution which i can use to retrive a last one hour records.

kiran

srikanthvja
March 14th, 2005, 07:21 AM
hi,

try this....

select * from tableName
where DATEDIFF(hh, modified_on, getdate()) <= 1

for more info go to DATEDIFF() - IN SQL SERVER

all the best........