Loretta, Your syntax appears to be correct. Below is an example of what we do (with some bits cut out) and it works.
strSQL = "INSERT INTO tblTempConsolidation SET " & _ "customerId = " & intCustomerId & ", " ............... strSQL = strSQL & "orderPrice = 0, " & _ "orderQty = " & intQty & ", " & _ "orderSource = 3, " & _ "245A = '" & Replace(strTitle,"'","''") & "', " & _ "100A = '" & Replace(strAuthor,"'","''") & "', " ............... objConn.Execute strSQL If you want to forward a little more code directly to me, I am more than happy to have a look. Regards, Greg -----Original Message----- From: Loretta [mailto:[EMAIL PROTECTED]] Sent: Wednesday, 27 March 2002 16:24 To: [EMAIL PROTECTED] Subject: ASP and MySQL I am having a problem inserting names with apostrophes into the MySQL database. I am using ASP as my front end with standard SQL statements to add, edit and delete records. I read the section in the manual on escape characters and have played around with many different variations trying to get it to work with absolutely no luck. The statement I am currently using looks like this: lname = Replace(Request.Form("lname"),"'","''") I have tried using the backslash character and several variations of different numbers of apostrophes. I would appreciate any help as this is the last problem to be solved before the database is functional. The rest of the debugging has been completed. Thank-you in advance, Loretta --------------------------------------------------------------------- Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive) To request this thread, e-mail <[EMAIL PROTECTED]> To unsubscribe, e-mail <[EMAIL PROTECTED]> Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php --------------------------------------------------------------------- Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive) To request this thread, e-mail <[EMAIL PROTECTED]> To unsubscribe, e-mail <[EMAIL PROTECTED]> Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php