Excel Error

Joined
Feb 12, 2009
Messages
1
Reaction score
0
Code:
Select "PROJECT" FROM ['Sheet 1$'] WHERE "CHECKNUMBER" = "ACH51000"

I recieve this error message when executing the above query

ERROR [07002] [Microsoft][ODBC Excel Driver] Too few parameters. Expected 1.
at System.Data.Odbc.OdbcConnection.HandleError(OdbcHandle hrHandle, RetCode retcode)
at System.Data.Odbc.OdbcCommand.ExecuteReaderObject(CommandBehavior behavior, String method, Boolean needReader, Object[] methodArguments, SQL_API odbcApiMethod)
at System.Data.Odbc.OdbcCommand.ExecuteReaderObject(CommandBehavior behavior, String method, Boolean needReader)
at System.Data.Odbc.OdbcCommand.ExecuteScalar()

The connection string is:
Driver={Microsoft Excel Driver (*.xls)};DriverId=790;Dbq=C:\HRA\test1\ap checks.xls;DefaultDir=C:\;Readonly=0;


What am I doing wrong?
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top