Results 1 to 2 of 2
  1. #1
    Join Date
    Aug 2010
    Posts
    1

    Unanswered: Help regarding query - (sysdate -60)

    Can someone please let me know what does this query means...

    select * from sales_invoices
    where
    invoice_date between sysdate - 30 and sysdate + 1

    Thanks,
    SP

  2. #2
    Join Date
    Jan 2004
    Location
    Croatia, Europe
    Posts
    4,094
    Provided Answers: 4
    This:
    Code:
    SQL> select sysdate, sysdate - 30, sysdate + 1
      2  from dual;
    
    SYSDATE             SYSDATE-30          SYSDATE+1
    ------------------- ------------------- -------------------
    04.08.2010 14:50:57 05.07.2010 14:50:57 05.08.2010 14:50:57
    
    SQL>
    Select all from table whose name is "sales_invoices" where "invoice_date" column's value is between "now - 30 days" and "now + 1 day".

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •