Insert string with " ' "

From: Date: Tue, 25 Jul 2000 13:00:31 +0000
Subject: Insert string with " ' "
Groups: php.db 
Request: Send a blank email to php-db+get-1465@lists.php.net to get a copy of this message
Hi people, I have a problem when I try to insert a string containing the character " ' ".I'm working with IBM DB2 v6.1 and php4. Example: ... $text = "I saw Tom's shoes"; $query = "INSERT INTO documents VALUES ('$text'); ... DB2 thinks that "I saw Tom" is the string to insert and "s shoes" is an error. What can I do? Mirko.

« previous php.db (#1465) next »