none
Too Few Parameters Expected 1 RRS feed

  • Question

  • I’m using Excel to ODBC to Access.  I am getting an error called ‘Too Few Parameters’.  I read the documentation here:

    http://www.mvps.org/access/queries/qry0013.htm

    That is quite good!  I do have a Form with a Start and End date on it, but I’m not using that anywhere in the query.  Furthermore, I’m not using VBA for this Query; it is 100% SQL.  Nevertheless, I have a Where clause in the Query, and that seems to be causing the problem.  If I eliminate that Where clause, the ODBC connection works fine.  With the Where in there, I’m getting the parameter-error and I kind of really need that Where clause . . . .

    Here is the Where:

    WHERE ((([Prior Period Adjustments].[MTD Active]) Is Null Or ([Prior Period Adjustments].[MTD Active])=True Or (([Prior Period Adjustments].[MTD Active]) Is Null Or ([Prior Period Adjustments].[MTD Active])=True) Or (([Prior Period Adjustments].[MTD Active]) Is Null Or ([Prior Period Adjustments].[MTD Active])=True) Or (([Prior Period Adjustments].[MTD Active]) Is Null Or ([Prior Period Adjustments].[MTD Active])=True) Or (([Prior Period Adjustments].[MTD Active]) Is Null Or ([Prior Period Adjustments].[MTD Active])=True)))

     

    There is more to the Query, but this is the part causing the error.  How can I modify that to make this thing work?

     

    Thanks!!

     

    Tuesday, March 1, 2011 12:31 AM

Answers

  • I’m using Excel to ODBC to Access.  I am getting an error called ‘Too Few Parameters’.  I read the documentation here:

    http://www.mvps.org/access/queries/qry0013.htm

    That is quite good!  I do have a Form with a Start and End date on it, but I’m not using that anywhere in the query.  Furthermore, I’m not using VBA for this Query; it is 100% SQL.  Nevertheless, I have a Where clause in the Query, and that seems to be causing the problem.  If I eliminate that Where clause, the ODBC connection works fine.  With the Where in there, I’m getting the parameter-error and I kind of really need that Where clause . . . .

    Here is the Where:

    WHERE ((([Prior Period Adjustments].[MTD Active]) Is Null Or ([Prior Period Adjustments].[MTD Active])=True Or (([Prior Period Adjustments].[MTD Active]) Is Null Or ([Prior Period Adjustments].[MTD Active])=True) Or (([Prior Period Adjustments].[MTD Active]) Is Null Or ([Prior Period Adjustments].[MTD Active])=True) Or (([Prior Period Adjustments].[MTD Active]) Is Null Or ([Prior Period Adjustments].[MTD Active])=True) Or (([Prior Period Adjustments].[MTD Active]) Is Null Or ([Prior Period Adjustments].[MTD Active])=True)))

     

    There is more to the Query, but this is the part causing the error.  How can I modify that to make this thing work?

     

    Thanks!!

     


    I'm confused as to why your WHERE clause specifies the same two alternative conditions 6 times.  I think something is odd there regardless of the source of the error.  As for the error, the most likely cause is that there is no field named "MTD Active" in the table or query, "Prior Period Adjustments".  Have you double-checked that?
    Dirk Goldgar, MS Access MVP
    Access tips: www.datagnostics.com/tips.html
    • Marked as answer by ryguy72 Tuesday, March 8, 2011 1:05 AM
    Tuesday, March 1, 2011 12:45 AM

All replies

  • I’m using Excel to ODBC to Access.  I am getting an error called ‘Too Few Parameters’.  I read the documentation here:

    http://www.mvps.org/access/queries/qry0013.htm

    That is quite good!  I do have a Form with a Start and End date on it, but I’m not using that anywhere in the query.  Furthermore, I’m not using VBA for this Query; it is 100% SQL.  Nevertheless, I have a Where clause in the Query, and that seems to be causing the problem.  If I eliminate that Where clause, the ODBC connection works fine.  With the Where in there, I’m getting the parameter-error and I kind of really need that Where clause . . . .

    Here is the Where:

    WHERE ((([Prior Period Adjustments].[MTD Active]) Is Null Or ([Prior Period Adjustments].[MTD Active])=True Or (([Prior Period Adjustments].[MTD Active]) Is Null Or ([Prior Period Adjustments].[MTD Active])=True) Or (([Prior Period Adjustments].[MTD Active]) Is Null Or ([Prior Period Adjustments].[MTD Active])=True) Or (([Prior Period Adjustments].[MTD Active]) Is Null Or ([Prior Period Adjustments].[MTD Active])=True) Or (([Prior Period Adjustments].[MTD Active]) Is Null Or ([Prior Period Adjustments].[MTD Active])=True)))

     

    There is more to the Query, but this is the part causing the error.  How can I modify that to make this thing work?

     

    Thanks!!

     


    I'm confused as to why your WHERE clause specifies the same two alternative conditions 6 times.  I think something is odd there regardless of the source of the error.  As for the error, the most likely cause is that there is no field named "MTD Active" in the table or query, "Prior Period Adjustments".  Have you double-checked that?
    Dirk Goldgar, MS Access MVP
    Access tips: www.datagnostics.com/tips.html
    • Marked as answer by ryguy72 Tuesday, March 8, 2011 1:05 AM
    Tuesday, March 1, 2011 12:45 AM
  • I got it worked out.  Deleted the original ODBC link and relinked the data.

    I think it was a Field!  It worked after I re-pointed the Connection String!!

    Tuesday, March 8, 2011 1:05 AM