I have a database that receive data from a form using Uploader.Form because I need to add an image as well. While adding new data, I got a ERROR message:
Desc : [Microsoft][ODBC Microsoft Access Driver] Syntax error (missing operator) in query expression 'idGuest <> 1 AND lcase(adImage) = '' AND adShortDesc = '0.75 x 150' Continuous Labels''.
SQL : SELECT * FROM ClassifiedAds WHERE idGuest <> 1 AND lcase(adImage) = '' AND adShortDesc = '0.75 x 150' Continuous Labels'
I believe that problem may has caused by the phrase in the adShortDesc that I included a apostrophy(') as feet which confused the SQL. I could change that ' to ft but that is not applicable because someone else may not like that. Is there a way to control input data when added so that SQL won't be confused and crashed like this? Thanks!
Desc : [Microsoft][ODBC Microsoft Access Driver] Syntax error (missing operator) in query expression 'idGuest <> 1 AND lcase(adImage) = '' AND adShortDesc = '0.75 x 150' Continuous Labels''.
SQL : SELECT * FROM ClassifiedAds WHERE idGuest <> 1 AND lcase(adImage) = '' AND adShortDesc = '0.75 x 150' Continuous Labels'
I believe that problem may has caused by the phrase in the adShortDesc that I included a apostrophy(') as feet which confused the SQL. I could change that ' to ft but that is not applicable because someone else may not like that. Is there a way to control input data when added so that SQL won't be confused and crashed like this? Thanks!