PL/SQL convert time stamp (linux/unix)

SELECT
  SUBJECT,
  RECPTYPE,
  RECPVALUE,
  OCCURREDDT
FROM
  US_EVENT.EVENT
  WHERE
   OCCURREDDT  >=  ROUND(SYSDATE-1 – TO_DATE(’01/01/1970′,’MM/DD/YYYY’))* 86400
   AND
   OCCURREDDT  <  ROUND(SYSDATE – TO_DATE(’01/01/1970′,’MM/DD/YYYY’))* 86400
   AND
   ALERTTYPE  IN  ( 1973, 1974  )

Leave a Reply

Your email address will not be published. Required fields are marked *