Results 1 to 3 of 3
  1. #1
    CoolGuy
    Guest

    Export Query to ASP and make it work?

    Anyone know how to export a query to a .asp file and make it work, :

    This is the error I get on the asp page:
    Error Type:
    Microsoft OLE DB Provider for ODBC Drivers (0x80040E10)
    [Microsoft][ODBC Microsoft Access Driver] Too few parameters. Expected 1.
    /strand/david01.asp, line 22

    This is how the ASP got formatted when I exported it from Access to .asp:
    Else
    sql = "SELECT [2K1-JobBook-Query].[JOBNUMBER], [2K1-JobBook-Query].[2K1-JobBook_CUSTOMERID], [2K1-JobBook-Query].[DATE_IN], [2K1-JobBook-Query].[SUBDIVISION], [2K1-JobBook-Query].[2K1-JobBook_CITY], [2K1-JobBook-Query].[2K1-JobBook_STATE], [2K1-JobBook-Query].[PLAN#], [2K1-JobBook-Query].[LOT], [2K1-JobBook-Query].[BLOCK], [2K1-JobBook-Query].[2K1-JobBook_ADDRESS], [2K1-JobBook-Query].[STATUS-OUTBOUND], [2K1-JobBook-Query].[STATUS-DATE-SCANNED-OUTBOUND] FROM [2K1-JobBook-Query] WHERE ((([2K1-JobBook-Query].[2K1-JobBook_CUSTOMERID])=""DAVID"") And (([2K1-JobBook-Query].[DATE_IN])>Date()-9) And (([2K1-JobBook-Query].[STATUS-OUTBOUND])=Yes)) "
    Set rs = Server.CreateObject("ADODB.Recordset")
    rs.Open sql, conn, 3, 3



    I think its to much info, let me know if I need to add.

  2. #2
    Lounger
    Join Date
    Feb 2001
    Location
    TX, USA
    Posts
    34
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Export Query to ASP and make it work?

    TRY THIS

    sql = "SELECT [2K1-JobBook-Query].[JOBNUMBER], [2K1-JobBook-Query].[2K1-JobBook_CUSTOMERID], [2K1-JobBook-Query].[DATE_IN], [2K1-JobBook-Query].[SUBDIVISION], [2K1-JobBook-Query].[2K1-JobBook_CITY], [2K1-JobBook-Query].[2K1-JobBook_STATE], [2K1-JobBook-Query].[PLAN#], [2K1-JobBook-Query].[LOT], [2K1-JobBook-Query].[BLOCK], [2K1-JobBook-Query].[2K1-JobBook_ADDRESS], [2K1-JobBook-Query].[STATUS-OUTBOUND], [2K1-JobBook-Query].[STATUS-DATE-SCANNED-OUTBOUND] FROM [2K1-JobBook-Query] WHERE ((([2K1-JobBook-Query].[2K1-JobBook_CUSTOMERID])='DAVID') And (([2K1-JobBook-Query].[DATE_IN])>Date()-9) And (([2K1-JobBook-Query].[STATUS-OUTBOUND])=Yes))

    I think the problem was the ""DAVID"" which should be 'DAVID'

  3. #3
    CoolGuy
    Guest

    Re: Export Query to ASP and make it work?

    Thanks that seems to work, now I just need to tweak it out a little. ... BRB

Posting Permissions

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