Link to home
Start Free TrialLog in
Avatar of careyb
careyb

asked on

ADODB.Connection error '800a0e80'

I'm getting this error running a select stmt that sums thousands of records. I think it may be a timing issue but I'm sure I've run larger queries.

ADODB.Connection error '800a0e80'
Operation has been cancelled by the user.

I can't find info on this error anywhere. Has anyone seen it , or have an idea where to look or how to troubleshoot?

My select is ...
strsql = "SELECT Fund, SUM(Shares) AS TotalShares, SUM(Cost) AS TotalCost
             FROM Transactions
             WHERE PlanMne ='" & Session("PlanMne") & "' "
             GROUP BY Fund
             ORDER BY Fund

I'm using the Advantage database from Extended Systems if that matters.

Thanks
Avatar of Guy Hengel [angelIII / a3]
Guy Hengel [angelIII / a3]
Flag of Luxembourg image

what are the data types of the fields Fund, shares and cost?
Avatar of careyb
careyb

ASKER

Fund is character, shares & cost are doubles
Avatar of careyb

ASKER

This query, by itself, works ok.  I'm now trying to run it on a plan that has many, many more records than any of the others I've tried, although I don't have an exact count.
SOLUTION
Avatar of jrram
jrram
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
is that sql as u put in prog ?

make it :

strsql =                " SELECT Fund, SUM(Shares) AS TotalShares, SUM(Cost) AS TotalCost " 
strsql &=              " FROM Transactions " 
strsql &=             " WHERE PlanMne ='" & Session("PlanMne") & "' "
strsql &=             " GROUP BY Fund " 
strsql &=             " ORDER BY Fund " 


Thanks
ASKER CERTIFIED SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of careyb

ASKER

jrram,
The default looks like it is set at 240. I doubled it, and the query ran until I got a script timeout. I'll try adjusting the value & see if I can get it.
Avatar of careyb

ASKER

programmer_bmb,
That's correct, I just tried to take out all of the extra stuff to make the question as clear as possible.
Avatar of careyb

ASKER

DragonLaird,
I added the index (wasn't there) and it hasn't yet solved the problem. I'll run it in the analyzer when I get back into the office.
Avatar of careyb

ASKER

good job guys. Thanks for the tip jrram, that is one of the things I have to do.