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!

Trunc date fonction for last year

812637Dec 9 2010 — edited Dec 10 2010
hi all,

how can I get the first of each month of last year,

OK, I explain more,

I have a live database and a datawarhose and I need to purge all data of the month before actual month but of last year for the live DB.

exp:

the sysdate is *2010/12/09* and I should delete all record of table X between *2009/11/01* and *2009/12/01*

how can I use the trunc fonction to do this automaticly

thx a lot for your help, and excuse me for my english

Edited by: 809634 on Dec 9, 2010 11:22 AM
This post has been answered by JuanM on Dec 9 2010
Jump to Answer
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Jan 7 2011
Added on Dec 9 2010
4 comments
885 views