Jump to content


Photo

cannot insert into 2nd table in data base


  • Please log in to reply
2 replies to this topic

#1 greggustin

greggustin
  • Members
  • PipPip
  • Member
  • 22 posts

Posted 13 July 2006 - 08:10 PM

made a very simple DB
1st table = no problem posing with html form => php => musql table
made 2nd table = cannot insert data
get his error message:
posting of display test data I cannot connect to the database because: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ''test1.test1table2' (first,last,age)VALUES ('greg', 'gustin', '99')' at line 1

#2 akitchin

akitchin
  • Staff Alumni
  • Advanced Member
  • 2,516 posts
  • LocationCalgary, AB, Canada

Posted 13 July 2006 - 08:12 PM

looks to me like you're using single quotes around the table name when you shouldn't be.  either use no quotes at all or use backticks (`).

#3 kenrbnsn

kenrbnsn
  • Staff Alumni
  • Advanced Member
  • 8,235 posts
  • LocationHillsborough, NJ, USA

Posted 13 July 2006 - 08:22 PM

Please post your code surrounded by [code][/code] tags.

Ken




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users