MYSQL Question..
#1

Okay, I have only recently noticed this and I am just wondering, is it just me or can you not have the apostrophe character in a mysql query? (')

Is there anyway around this?

Thanks in advance!
Reply
#2

You have to escape the string you want to use in a query. There should be a native like "mysql_escape_string" provided by the MySQL plugin you are using. Also don't escape the whole query string, only the string you want to use in the query.
Reply
#3

Quote:
Originally Posted by maddinat0r
Посмотреть сообщение
You have to escape the string you want to use in a query. There should be a native like "mysql_escape_string" provided by the MySQL plugin you are using. Also don't escape the whole query string, only the string you want to use in the query.
Great, thank you very much!
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)