Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Strange Error

Status
Not open for further replies.

sparky68

Programmer
Feb 27, 2002
11
0
0
US
Here is everything... The page works... However at times I get the error that I listed below... I have a second sql on this page which works fine, but that reads from a table not a query... I am guessing that obdc isnt liking using data from a query... I tried using jet with same results...


In my asp page the sql is:
strsql = "select * from qrybowling"

Qrybowling is:
SELECT tblBowlers.BowlerID, tblBowlers.BowlerName, tblEvents.EventID, tblEvents.EventDate, tblEvents.EventName, (select score from tblscores where tblscores.eventid=tblevents.[EventID] and tblscores.bowlerid=tblpledge.[BowlerID] and tblscores.gamenumber=1) AS Game1, (select score from tblscores where tblscores.eventid=tblevents.[EventID] and tblscores.bowlerid=tblpledge.[BowlerID] and tblscores.gamenumber=2) AS Game2, (select score from tblscores where tblscores.eventid=tblevents.[EventID] and tblscores.bowlerid=tblpledge.[BowlerID] and tblscores.gamenumber=3) AS Game3, [game1]+[game2]+[game3] AS GameTotal,
Round(([Game1]+[Game2]+[Game3])/3,0) AS Average, tblPledge.PerPinPledge,
Format(Round([perpinpledge]*[GameTotal],2),"Currency") AS PerPinTotal, tblPledge.FlatPledge, [flatpledge]+[perpintotal] AS TotalPledge FROM tblBowlers INNER JOIN (tblEvents INNER JOIN tblPledge ON
tblEvents.EventID=tblPledge.EventID) ON tblBowlers.BowlerID=tblPledge.BowlerID;

The error I'm getting is:
Microsoft OLE DB Provider for ODBC Drivers error '80040e10'
[Microsoft][ODBC Microsoft Access Driver] Too few parameters. Expected 3.
/bowling/events/eventresults.asp, line 21

Line 21 is:
objRecordSet.Open strSQL, objConn, 0, 1 'forward only, read only
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top