$accname =$_POST['uaccountname'];
$aid =$_POST['aid'];
if($_SERVER['REQUEST_METHOD'] == 'POST' && $_POST['submit'] =='update account')
{
$qry = "UPDATE accounts SET acc_name = $accname WHERE acc_id =$aid";
mysql_query($qry) or die(mysql_error());
}
it gives folling 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 '' at line 1