SQL Problem with quotes
When I receive an SMS, sometimes my messages are not inserted into the database. How can I solve this problem?
When a message is received, an SQL string is composed, then it is passed to the database server. The SQL string composition is based on an SQL template defined in the Database Settings form. If an incoming message contains an apostrophe (') or a quotation mark ("), the SQL statement becomes invalid when the message text is inserted into the template.
Our software provides a mechanism to replace the apostrophe (') and the quotation
mark (") in the received message before it is inserted into the
SQL template. On the Database settings form you can specify what caracter sequence should
be used instead of these characters.
Note: On
Sybase, MSSql and on MySql, you should substitue the apostrophe (') with
two apostrophes ('') and you should do the same for quotation
marks.
More information