SQL in Visiual FoxPro


DevX Home    Today's Headlines   Articles Archive   Tip Bank   Forums   

Results 1 to 3 of 3

Thread: SQL in Visiual FoxPro

  1. #1
    MANGO Guest

    SQL in Visiual FoxPro


    WHat is wrong in the below SQL statement?

    --------------
    Select * from sal_hdr_tbl where ord_dte = date('01/01/1999')
    --------------


    It come out a error message:
    ----------------
    TOO FEW Argument
    ----------------

    MANGO


  2. #2
    Michael Levy Guest

    Re: SQL in Visiual FoxPro

    The Visual FoxPro DATE() function has the following signature

    DATE(nYear, nMonth, nDay)

    BTW, you'll find execellent support for Visual FoxPro at
    www.universalthread.com.

    -Mike
    --
    Michael Levy MCDBA, MCSD, MCT
    michaell@gasullivan.com
    "MANGO" <mong@mango.i-p.com> wrote in message
    news:3aa4d471$1@news.devx.com...
    >
    > WHat is wrong in the below SQL statement?
    >
    > --------------
    > Select * from sal_hdr_tbl where ord_dte = date('01/01/1999')
    > --------------
    >
    >
    > It come out a error message:
    > ----------------
    > TOO FEW Argument
    > ----------------
    >
    > MANGO
    >




  3. #3
    SC Guest

    Re: SQL in Visiual FoxPro


    >Select * from sal_hdr_tbl where ord_dte = date('01/01/1999')


    Select * from table where ord_dte = {^2001.03.03}

    In order to keep your stuff clean, set your date format to ANSI and STRICTDATE
    to 1 (constants). If that works then you can "work backwards" and try using
    date() etc.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
HTML5 Development Center
 
 
FAQ
Latest Articles
Java
.NET
XML
Database
Enterprise
Questions? Contact us.
C++
Web Development
Wireless
Latest Tips
Open Source


   Development Centers

   -- Android Development Center
   -- Cloud Development Project Center
   -- HTML5 Development Center
   -- Windows Mobile Development Center