By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
425,478 Members | 1,374 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 425,478 IT Pros & Developers. It's quick & easy.

Subscript out of range during execution Select statement

P: 1
I am getting a Subscript out of range after executing the following command
Set oRstPick = connTemp.Execute(sSQL)

It is a simple query:
sSQL = "SELECT idCategory, categoryDesc, idParentCategory FROM categories WHERE idCategory <> 1;"

My connection string looks like this:

connString = "Driver={Microsoft Access Driver (*.mdb)};DBQ=" &server.MapPath("../database/comersus.mdb")&";"
set connTemp=server.createobject("adodb.connection")
connTemp.Open connString

I am allocating like this:
Dim sSendBack, sSQL, sCurItem, connString
Dim oRstPick, oCats, connTemp, sValueName

It works as long as the number of rows in the Access database is less than 112 rows. When I have 112 rows or more I get the 'Subscript out of range'

Any ideas?

Thanks

Dave
Sep 18 '06 #1
Share this question for a faster answer!
Share on Google+

Post your reply

Sign in to post your reply or Sign up for a free account.