Ask a Question related to ASP Database, Design and Development.
-
% =joe % #1
I'm baffled...
Help...
This is my error
(I've searched all over help regarding the famous 80040e10 error)
Microsoft JET Database Engine error '80040e10'
No value given for one or more required parameters.
orderSearchDetails.asp, line 36
Here's my code...
Dim searchChoice
searchChoice = Request.form("searchChoice")
Select Case searchChoice
Case "orderID"
searchVarible = Request.form("searchBox")
valueID = "orderID"
Case "email"
searchVarible = Request.form("searchBox")
valueID = "'email'"
Case "lName"
searchVarible = Request.form("searchBox")
valueID = "'lName'"
end select
'Connect to the included MS Access database
Set MyConn = Server.CreateObject("ADODB.Connection")
MyConn.Open "Provider=Microsoft.Jet.OLEDB.4.0; Data Source=" &
Server.MapPath("../database/metacart.mdb") & ";"
Set MyRS = Server.CreateObject("ADODB.Recordset")
mySQL = "SELECT orderID,orderDate,fName,lName,email,orderStatus FROM
orders WHERE "&searchVarible&" LIKE "&valueID&" ORDER BY orderDate
DESC;"
'Opened as Read-Only
MyRS.Open mySQL, MyConn, 3 ' <-- LINE 36 IS HERE
'UNCOMMENT TO VIEW SQL STATEMENT--------------------------------
'Response.Write(mySQL)
'Response.End
I've using the select/case because two of my search fields are text
and one is numeric.
Thanks in advance
% =joe % Guest
-
Baffled by CFLOCK
I have a question about using CFLOCK. I am a self-taught programmer running CF 4.5 (and, I should say, helped a lot by the kind people on this... -
baffled by Access 2002 - Any ideas
I have this simple shopping cart that I am working with with two databases - products & orders -orders has two tables: orders & itemsOrdered... -
Can't extract text from PDF, baffled...
Hi all, I'm not able to extract the text from a PDF. I copy and then when I paste, all I get is SPACES, bizarre. I even tried the batch process... -
Baffled? This IZ a REAL PUZZLER!!
I imported a Photoshop 7 file into Corel Draw 9 and typed some text on top . At first the PSD file was 46% transparent. The font in Corel is Black... -
Bob Barrows #2
Re: I'm baffled...
% =joe % wrote:
Why haven't you shown us the SQL statement? That is the key to debugging> Help...
>
> This is my error
> (I've searched all over help regarding the famous 80040e10 error)
>
>
> Microsoft JET Database Engine error '80040e10'
> No value given for one or more required parameters.
> orderSearchDetails.asp, line 36
>
>
>
> Here's my code...
>
>
> Dim searchChoice
> searchChoice = Request.form("searchChoice")
>
> Select Case searchChoice
> Case "orderID"
> searchVarible = Request.form("searchBox")
> valueID = "orderID"
>
> Case "email"
> searchVarible = Request.form("searchBox")
> valueID = "'email'"
>
> Case "lName"
> searchVarible = Request.form("searchBox")
> valueID = "'lName'"
>
> end select
>
> 'Connect to the included MS Access database
> Set MyConn = Server.CreateObject("ADODB.Connection")
> MyConn.Open "Provider=Microsoft.Jet.OLEDB.4.0; Data Source=" &
> Server.MapPath("../database/metacart.mdb") & ";"
> Set MyRS = Server.CreateObject("ADODB.Recordset")
>
> mySQL = "SELECT orderID,orderDate,fName,lName,email,orderStatus FROM
> orders WHERE "&searchVarible&" LIKE "&valueID&" ORDER BY orderDate
> DESC;"
> 'Opened as Read-Only
> MyRS.Open mySQL, MyConn, 3 ' <-- LINE 36 IS HERE
>
> 'UNCOMMENT TO VIEW SQL STATEMENT--------------------------------
> 'Response.Write(mySQL)
> 'Response.End
>
this error, which usually means that you have referred to a field which does
not exist, usually due to misspelling, or due to using a reserved keyword
for your field name (which does not appear to be the case here).
You can avoid the error entirely in the future by using saved parameter
queries instead of dynamic sql. See some of the other posts I've made today
for examples
HTH,
Bob Barrows
--
Microsoft MVP - ASP/ASP.NET
Please reply to the newsgroup. This email account is my spam trap so I
don't check it very often. If you must reply off-line, then remove the
"NO SPAM"
Bob Barrows Guest
-
Aaron Bertrand - MVP #3
Re: I'm baffled...
> MyRS.Open mySQL, MyConn, 3 ' <-- LINE 36 IS HERE
So, UNCOMMENT, run again, and show us the result.>
> 'UNCOMMENT TO VIEW SQL STATEMENT--------------------------------
> 'Response.Write(mySQL)
Aaron Bertrand - MVP Guest
-
% =joe % #4
Re: I'm baffled...
Sorry for the mix up. I did run it (uncommented) and the result was:
> Microsoft JET Database Engine error '80040e10'
> No value given for one or more required parameters.
> orderSearchDetails.asp, line 36
MyRS.Open mySQL, MyConn, 3 ' <-- LINE 36
Here is my sql statement:
mySQL = "SELECT orderID,orderDate,fName,lName,email,orderStatus FROM> orders WHERE "&searchVarible&" LIKE "&valueID&" ORDER BY orderDate
> DESC;"
I did check and re-check the spelling of my field names, and I am not
using any reserved words. That's why I'm turing to the justice league
for help.
I am still unsure about using cursor types and lock types. Could that
be something?
Thanks again
% =joe % Guest
-
Ray at #5
Re: I'm baffled...
I think they were after the result of
RESPONSE.WRITE MYSQL
that you copy and paste from your browser, not the code.
Ray at work
"% =joe %" <jweiss@lanelabs.com> wrote in message
news:1324914.0402061648.6ddd79e1@posting.google.co m...> Sorry for the mix up. I did run it (uncommented) and the result was:
>>> > Microsoft JET Database Engine error '80040e10'
> > No value given for one or more required parameters.
> > orderSearchDetails.asp, line 36
>
>
> MyRS.Open mySQL, MyConn, 3 ' <-- LINE 36
>
> Here is my sql statement:
> mySQL = "SELECT orderID,orderDate,fName,lName,email,orderStatus FROM>> > orders WHERE "&searchVarible&" LIKE "&valueID&" ORDER BY orderDate
> > DESC;"
>
> I did check and re-check the spelling of my field names, and I am not
> using any reserved words. That's why I'm turing to the justice league
> for help.
>
> I am still unsure about using cursor types and lock types. Could that
> be something?
>
> Thanks again
Ray at Guest
-
Chris Hohmann #6
Re: I'm baffled...
"% =joe %" <jweiss@lanelabs.com> wrote in message
news:1324914.0402061648.6ddd79e1@posting.google.co m...You have to comment out line 36 or it's never going to get to lines 39> Sorry for the mix up. I did run it (uncommented) and the result was:
>>> > Microsoft JET Database Engine error '80040e10'
> > No value given for one or more required parameters.
> > orderSearchDetails.asp, line 36
>
>
> MyRS.Open mySQL, MyConn, 3 ' <-- LINE 36
>
> Here is my sql statement:
> mySQL = "SELECT orderID,orderDate,fName,lName,email,orderStatus FROM>> > orders WHERE "&searchVarible&" LIKE "&valueID&" ORDER BY orderDate
> > DESC;"
>
> I did check and re-check the spelling of my field names, and I am not
> using any reserved words. That's why I'm turing to the justice league
> for help.
>
> I am still unsure about using cursor types and lock types. Could that
> be something?
>
> Thanks again
and 40.
Chris Hohmann Guest
-
% =joe % #7
Re: I'm baffled...
I did coment it out, just wasn't clear about it, sorry.
Here's my origional code...
Dim searchChoice
searchChoice = Request.form("searchChoice")
Select Case searchChoice
Case "orderID"
searchVarible = Request.form("searchBox")
valueID = "orderID"
Case "email"
searchVarible = Request.form("searchBox")
valueID = "'email'"
Case "lName"
searchVarible = Request.form("searchBox")
valueID = "'lName'"
end select
'Connect to the included MS Access database
Set MyConn = Server.CreateObject("ADODB.Connection")
MyConn.Open "Provider=Microsoft.Jet.OLEDB.4.0; Data Source=" &
Server.MapPath("../database/metacart.mdb") & ";"
Set MyRS = Server.CreateObject("ADODB.Recordset")
mySQL = "SELECT orderID,orderDate,fName,lName,email,orderStatus FROM
orders WHERE "&searchVarible&" LIKE "&valueID&" ORDER BY orderDate
DESC;"
'Opened as Read-Only
MyRS.Open mySQL, MyConn, 3 ' <-- LINE 36 IS HERE
Response.Write(mySQL)
Response.End
Here is the error I got...
> Microsoft JET Database Engine error '80040e10'
> No value given for one or more required parameters.
> orderSearchDetails.asp, line 36
I have read much of 80040e10 errors and making sure that there aren't
any mispesslings in my field names (and they're not)
Could this be a lock type issue (that is where I am a bit fuzzy).
Thanks again
% =joe % Guest
-
Bob Barrows #8
Re: I'm baffled...
% =joe % wrote:
Sheesh! Change your code to this:
----------------------------------------------------------------------------
---
mySQL = "SELECT orderID,orderDate,fName,lName,email,orderStatus FROM
orders WHERE "&searchVarible&" LIKE "&valueID&" ORDER BY orderDate
DESC;"
Response.Write(mySQL)
Response.End
'Connect to the included MS Access database
Set MyConn = Server.CreateObject("ADODB.Connection")
MyConn.Open "Provider=Microsoft.Jet.OLEDB.4.0; Data Source=" &
Server.MapPath("../database/metacart.mdb") & ";"
Set MyRS = Server.CreateObject("ADODB.Recordset")
'Opened as Read-Only
MyRS.Open mySQL, MyConn, 3 ' <-- LINE 36 IS HERE
------------------------------------------------------------------
You need to see the result of Response.Write(mySQL). If that does not tell
you what the problem is (you should copy and paste the result from the
browser window into the SQL View of the Access query builder to try and
debug it), then you need to show us the structure of the orders table along
with the result of the response.write.
Bob Barrows
--
Microsoft MVP - ASP/ASP.NET
Please reply to the newsgroup. This email account is my spam trap so I
don't check it very often. If you must reply off-line, then remove the
"NO SPAM"
Bob Barrows Guest
-
Chris Hohmann #9
Re: I'm baffled...
"% =joe %" <jweiss@lanelabs.com> wrote in message
news:1324914.0402080946.33758a35@posting.google.co m...Line 36 is not commented out. Please replace this:> I did coment it out, just wasn't clear about it, sorry.
>
> Here's my origional code...
>
> Dim searchChoice
> searchChoice = Request.form("searchChoice")
>
> Select Case searchChoice
> Case "orderID"
> searchVarible = Request.form("searchBox")
> valueID = "orderID"
>
> Case "email"
> searchVarible = Request.form("searchBox")
> valueID = "'email'"
>
> Case "lName"
> searchVarible = Request.form("searchBox")
> valueID = "'lName'"
>
> end select
>
> 'Connect to the included MS Access database
> Set MyConn = Server.CreateObject("ADODB.Connection")
> MyConn.Open "Provider=Microsoft.Jet.OLEDB.4.0; Data Source=" &
> Server.MapPath("../database/metacart.mdb") & ";"
> Set MyRS = Server.CreateObject("ADODB.Recordset")
>
> mySQL = "SELECT orderID,orderDate,fName,lName,email,orderStatus FROM
> orders WHERE "&searchVarible&" LIKE "&valueID&" ORDER BY orderDate
> DESC;"
> 'Opened as Read-Only
> MyRS.Open mySQL, MyConn, 3 ' <-- LINE 36 IS HERE
>
> Response.Write(mySQL)
> Response.End
>
>
> Here is the error I got...
>>> > Microsoft JET Database Engine error '80040e10'
> > No value given for one or more required parameters.
> > orderSearchDetails.asp, line 36
>
> I have read much of 80040e10 errors and making sure that there aren't
> any mispesslings in my field names (and they're not)
>
> Could this be a lock type issue (that is where I am a bit fuzzy).
>
> Thanks again
MyRS.Open mySQL, MyConn, 3 ' <-- LINE 36 IS HERE
With this:
'MyRS.Open mySQL, MyConn, 3 ' <-- LINE 36 IS HERE
Notice, there's an apostrophe (') at the start of the line.
-Chris Hohmann
Chris Hohmann Guest



Reply With Quote

