Jump to content


Photo

Where Exists Help


  • Please log in to reply
1 reply to this topic

#1 emmy

emmy

    Member

  • Members
  • PipPip
  • 12 posts

Posted 31 October 2012 - 04:40 PM

I am having the same issue here but on postgreSQL database. I keep getting SYNTAX ERROR error at the update line, please can someone help

$query = "Select * from fieldtally where 'pipeno' = $pipeno;
BEGIN;
INSERT INTO fieldtally(pipeno,wthick,djointno,heatno1)VALUES('$pipeno','$wthick','$djointno','$heatno1'); WHERE EXIST, UPDATE fieldtally set 'pipeno'=$pipeno,'wthick'=$wthick,'djointno'=$djointno,'heatno1'=$heatno1);
END";




#2 Christian F.

Christian F.

    Advanced Member

  • Gurus
  • 3,055 posts
  • LocationNorway

Posted 24 January 2013 - 07:41 AM

Try to remove the single quotes around the field names.
Keeping it simple.




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users

Cheap Linux VPS from $5
SSD Storage, 30 day Guarantee
1 TB of BW, 100% Network Uptime

AlphaBit.com