jpergega Posted February 5, 2015 Share Posted February 5, 2015 Hi My query is like this and is saying there is an syntax error near 'cusomter_id')}' what am I doing wrong here? $query = " INSERT INTO `imglib` ( `img_name`, `img_type`, `img_size`, `img`,`customer_id` ) VALUES ( '{$name}', '{$mime}', {$size}, '{$data}','{SELECT(customer_id FROM customer WHERE customer_id='cusomter_id')}' )"; Thanks Link to comment Share on other sites More sharing options...
yaragallamurali Posted February 5, 2015 Share Posted February 5, 2015 VALUES ( '{$name}', '{$mime}', {$size}, '{$data}','{(SELECTcustomer_id FROM customer WHERE customer_id='cusomter_id')}' )"; i am not sure but try this. Link to comment Share on other sites More sharing options...
jpergega Posted February 5, 2015 Author Share Posted February 5, 2015 (edited) Thanks I found the solution Edited February 5, 2015 by jpergega Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now