Oracle last week last day of the inquiry date

Last week, the last day of the inquiry date

TO_CHAR((select trunc(sysdate,'d')-1 from dual),'YYYY-MM-DD')

Query on the last day of the month date

TO_CHAR((select trunc(sysdate,'mm')-1 from dual),'YYYY-MM-DD')

 

Guess you like

Origin www.cnblogs.com/flyingpigacc/p/10962643.html
Recommended