Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

PHP & MySQL

Status
Not open for further replies.

BB101

Programmer
May 23, 2001
337
GB
I am using PHP and MySQL on a 2k dev box to be uploaded to a linux box

I have a piece of SQL

INSERT INTO `contracts` (`key`, `content`) VALUES (1,'blah blah blah
character 39 is a single speach mark '+CHAR(39)+' blah blah blah')

Instead of inserting: 'blah blah blah character 39 is a single speach mark '
blah blah blah
It inserts 0
All variations work fine when there is no single speachies

help?

--BB
 
INSERT INTO contracts ('key', 'content') VALUES ('1','blah blah blah
character 39 is a single speach mark '+CHAR(39)+' blah blah blah')

Don't use the backtiks ` in your sql statement, use single ' or double " quotes.

You don't need them around the table name.
______________________________________________________________________
There's no present like the time, they say. - Henry's Cat.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top