
February 25th, 2000, 12:41 AM
|
|
Contributing User
|
|
Join Date: Dec 2002
Posts: 14,575
  
Time spent in forums: < 1 sec
Reputation Power: 22
|
|
|
<i><b>Originally posted by : steve schofield (sschofield@aspfree.com)</b></i><br />debugging sql statements stink! even a seasoned programmer runs into this. One thing i found was before your conn.execute do a response.write strsql. this statement will print out in the page. It'll still error but then copy and paste the sql statement into your access query window and then debug from there. <br /><br />http://www.asptoday.com/default.asp?art=19990721.htm <br /><br />here is an article i did on asptoday about this<br /><br />steve<br /><br /><br /><br /><br />------------<br />Kirk at 2/24/2000 10:26:30 AM<br /><br /><br />I'm very frustrated. I'm trying to run the following query:<br /><br /><%<br />Response.Write strid&"<br>"<br />strquery="SELECT clientcompany.name as Company, clientcompany.id, clientoffice.*, clientcontact.* "<br />strquery = strquery & "FROM clientcompany, clientcontact, clientoffice "<br />strquery = strquery & "WHERE clientcontact.office_id = " & strid<br />strquery = strquery & " AND clientcompany.id = "<br />strquery = strquery & "(SELECT clientoffice.clientcompany_id "<br />strquery = strquery & "FROM clientoffice "<br />strquery = strquery & "WHERE clientoffice.id = " & strid & ")"<br />Response.Write strquery & "<br><br>"<br />set objRS = objConn.execute(strquery)%><br /><br />All I keep getting is the following error:<br /><br />Microsoft OLE DB Provider for ODBC Drivers error '80040e10' <br /><br />[Microsoft][ODBC Microsoft Access Driver] Too few parameters. Expected 1. <br /><br />/office.asp, line 19 <br /><br />Line 19 is my execute statement<br />Please help!!!! I'm floundering!<br />Thanks.<br /><br /><br />
|