inserts not working
Posted: Wed May 25, 2011 8:58 am
I've tried '$variable', '.$variable.', ' " .$variable. " ', Maybe I'm just tired after so many hours but I can't see why my last two INSERT INTO are not working. Someone please help. Thanks.
Code: Select all
$entries = "INSERT INTO allowances (totalGrossPay) VALUES ('$totalGrossPay') WHERE SSN = '".$SSN."'";
mysql_query ($entries);
$SQL = "INSERT INTO ".$tableName." (SSN, Last, First, payRate, grossPay, status, fedAllowance, stateAllowance, fedExtra, stateExtra, stateEstimated, fedTax, SS, Med, stateTax,
garnishment, FUTA, CalUI, ETT, SDI, employerSS) VALUES ('$SSN', '$Last', '$First', '$payRate', '$grossPay', '$status', '$fedAllowance', '$stateAllowance', '$fedExtra',
'$stateExtra', '$stateEstimated', '$fedTax', '$SS', '$Med', '$stateTax', '$garnishment', '$FUTA', '$CalUI', '$ETT', '$SDI, '$employerSS')";
mysql_query ($SQL);