|
Classic ASP Databases Discuss using ASP 3 to work with data in databases, including ASP Database Setup issues from the old P2P forum on this specific subtopic. See also the book forum Beginning ASP.NET Databases for questions specific to that book. NOT for ASP.NET 1.0, 1.1, or 2.0. |
Welcome to the p2p.wrox.com Forums.
You are currently viewing the Classic ASP Databases section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
|
|
|
January 5th, 2006, 03:20 AM
|
Authorized User
|
|
Join Date: Jan 2006
Posts: 10
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
Question
Please help me I have an error In this line
strdml="INSERT INTO order (Id,orderdate,type,comm,disc,consigneename,lcno,da te,amount,expdate,buyerorderno,buyerorderdate,curr ency,remarks,commagent,style,model,deldate,unit)VA LUES ('"&Id&"','"&orderdate&"','"&otype&"','"&comm&"',' "&disc&"','"&consigneename&"','"&lcno&"','"&ldate& "','"&lamount&"','"&expdate&"','"&buyerorderno&"', '"&buyerorderdate&"','"&bcurrency&"','"&remarks&"' ,'"&commagent&"','"&style&"','"&model&"','"&deldat e&"','"&unit&"')"
And the error is
Syntax error in INSERT INTO statement.
But the form takes values ,when saw through Response.write strdml
Please help mein this
|
January 5th, 2006, 05:21 AM
|
Friend of Wrox
|
|
Join Date: Jul 2003
Posts: 683
Thanks: 0
Thanked 1 Time in 1 Post
|
|
Which db are you using?
Can you post the output from Response.Write strdml, please?
Cheers,
Chris
|
January 10th, 2006, 05:42 AM
|
Authorized User
|
|
Join Date: Jan 2006
Posts: 10
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
Please help me why this error comes
My Querry
strdml="INSERT INTO Id (Id,orderdate,type,comm,disc,consigneename,lcno,ld ate,lamount,expdate,buyerorderno,buyerorderdate,bc urrency,remarks,commagent,style,model,deldate,unit )values('"&Id&"','"&orderdate&"','"&otype&"','"&co mm&"','"&disc&"','"&consigneename&"','"&lcno&"','" &ldate&"','"&lamount&"','"&expdate&"','"&buyerorde rno&"','"&buyerorderdate&"','"&bcurrency&"','"&rem arks&"','"&commagent&"','"&style&"','"&model&"','" &deldate&"','"&unit&"')"
objcon.Execute strdml
response.write strdml
error is
Data type mismatch in criteria expression.
I am using ms access database
Please help me b'coz I can't go further in my work
|
January 10th, 2006, 07:20 AM
|
Friend of Wrox
|
|
Join Date: Jul 2003
Posts: 683
Thanks: 0
Thanked 1 Time in 1 Post
|
|
In access you need to surround date values with hashes - ... , #" & ldate & "#, ... etc., integer values do not need single quotes around them.
If you still have problems, can you post the output from Response.Write strdml, please?
HTH,
Chris
|
Similar Threads
|
Thread |
Thread Starter |
Forum |
Replies |
Last Post |
question |
maheshraju |
ASP.NET 2.0 Basics |
3 |
March 13th, 2008 08:54 AM |
Question |
Ashwini |
Classic ASP Databases |
1 |
January 4th, 2006 06:55 AM |
Question? |
Calibus |
Classic ASP Databases |
8 |
August 6th, 2004 08:25 AM |
a question |
gorji |
C++ Programming |
2 |
August 11th, 2003 07:41 AM |
|
|