2 Replies Latest reply: Dec 31, 2012 11:43 PM by user503635 RSS

    calculate last 5 months

    user12957777
      How to calculate last 5 months from sysdate ?

      The statement - SELECT TO_CHAR(SYSDATE,'YYYYMM')-1 FROM DUAL gives 201300. The desired output is 201212, 201211, 201210, 201209, 201208.

      Sanjay