Please debug this mysql query?
by bsabarnowl
Question by Affs Dsfs: Please debug this mysql query?
haiii iam having trouble opening a page in php that uses mysql script
it was working finee till last dayy
today when i open it, it throws an error 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 ‘2010-10-10′ where sold =’NotSold’ AND modelnumber = ‘Q10’ AND shop = ‘mobilecorn’ at line 1
and the script is
$ query=”UPDATE sales SET sold =’Sold, SET date = ‘2010-10-10′ where sold =’NotSold’ AND modelnumber = ‘$ modelnumber’ AND shop = ‘$ shop’ limit 1″;
what is the fault ?
Best answer:
Answer by anon
You have only one tick after Sold. You need another. Good luck.
‘Sold, SET date
Give your answer to this question below!