PDA

View Full Version : simple sql problem


thesavior
04-26-2006, 07:12 AM
My query:

'INSERT INTO '.$db_prefix."config (conf_name, conf_value) VALUES('$conf_name', $conf_value)"

is returning:

You have an error in your SQL syntax near ')' at line 1 (Errno: 1064)

any ideas how to fix it?

GJay
04-26-2006, 09:25 AM
first step of debugging sql errors:
mysql_query($query) or die($query);

With no idea of what either of those variables do or are supposed to contain, it makes things difficult- why does the second one not have quotes? have they been escape'd somewhere else?