Skip to Main Content

SQL & PL/SQL

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Query to get Weekly Report

792290Apr 13 2011 — edited Apr 13 2011
Hello,
I wrote a query to get weekly report, which should start from Sunday to Saturday a typical week. for example the week is 04/03/2011 to 04/09/2011 i run the query on or Job on say on anyday of the week of 04/10/2011, 04.11.2011 etc.. here is my query, but this seems to work from the sysdate to - 7 days which doesn't get the sunday to sat requirement.. can someone please help..

select uid, psn, TO_char(date_in,'mm/dd/yyyy')
FROM TEST
WHERE uid like '%ST%'
and date_in > trunc(SYSDATE) -7
ORDER BY date_in ASC;
Thank you.
This post has been answered by Centinul on Apr 13 2011
Jump to Answer
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on May 11 2011
Added on Apr 13 2011
7 comments
2,446 views