Need help with calculating date
Hi..
I need help calculating a date value.. This is the script:
select
target_name,
target_type,
sum(trunc((nvl(end_timestamp,sysdate)-start_timestamp)*24)) total_hours
FROM mgmt$Availability_history
where target_name = 'ORCL'
group by target_name,availability_status, target_type
/
This scripts operates against the OEM view mgmt$availability_history. The results of this query are in total hours for a six month period. I need to limit the time period to 30 days of values. How would I best accomplish this?
Thanks..
NS
0