Syntax Error 1064 (I am a newbie)
Posted by: Elizabeth Block
Date: June 10, 2015 02:49PM

INSERT INTO 'jobs.companyID' SELECT*FROM 'companies.companyID' WHERE '';

The above is resulting in a #1064 error, "#1064 - 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 ''jobs.companyID' SELECT*FROM 'companies.companyID' WHERE '' at line 1

My tables are 'companies' and 'jobs' and the referenced fields are correctly labeled.

I am trying to match a company name between the two tables and then if there is a match, to place the company ID which is primary in the company table into the jobs field called companyID. I am using MYSQL 5.1.55

Options: ReplyQuote

Written By
Syntax Error 1064 (I am a newbie)
June 10, 2015 02:49PM

Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.