terrid Posted October 6, 2010 Share Posted October 6, 2010 Hi Any ideas why the following is giving me an error: $result = mysql_query("update records_table set logo_id = (select id from logos where name = substring(retailer_message,12))"); Thanks Link to comment https://forums.phpfreaks.com/topic/215283-mysql-error-in-query/ Share on other sites More sharing options...
kickstart Posted October 6, 2010 Share Posted October 6, 2010 Hi What is the error you are getting? All the best Keith Link to comment https://forums.phpfreaks.com/topic/215283-mysql-error-in-query/#findComment-1119564 Share on other sites More sharing options...
BlueSkyIS Posted October 7, 2010 Share Posted October 7, 2010 you need to quote the value in your sub-select. Link to comment https://forums.phpfreaks.com/topic/215283-mysql-error-in-query/#findComment-1119786 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.