This INSERT query isn't working correctly; need set of eyes
Posted: Thu Jun 05, 2003 6:34 pm
Hello. Here's the insert statement which I'm executing:
mysql_query("INSERT INTO CustomerEntry (ClientSalesID, ClientNameID, FName, LName, StreetNum, StreetName, Zip, Telephone, Email, GuessNumber, GuessDate, CurrVehicleYr, CurrVehicleMake, CurrVehicleModel, LastVehiclePurchase, VehicleType, CurrPayment, MostImportantNewCar, Marketing) values ('$FName', '$LName', '$StreetNum', '$StreetName', '$Zip', '$Telephone', '$Email', '$GuessNumber', '$DateOfSubmit', '$CurrVehicleYear', '$CurrVehicleMake', '$CurrVehicleModel', '$VehiclePurchase', '$CurrVehicleType', '$CurrPayment', '$MostImportantNewCar', '$Marketing')");
[Admin Edit: added some spaces to the SQL statement to allow it to wrap]
I have a connection to MySQL, because a previous query works fine. Here's the fields I have in the MySQL table, called CustomerEntry
CustomerEntryID, ClientSalesID, ClientNameID, FName, LName, StreetNum, StreetName, Zip, Telephone, Email, GuessNumber, GuessDate, CurrVehicleYr, CurrVehicleMake, CurrVehicleModel, LastVehiclePurchase, VehicleType, CurrPayment, MostImportantNewCar and Marketing
Do you see any typo? Nothing is inserted.
mysql_query("INSERT INTO CustomerEntry (ClientSalesID, ClientNameID, FName, LName, StreetNum, StreetName, Zip, Telephone, Email, GuessNumber, GuessDate, CurrVehicleYr, CurrVehicleMake, CurrVehicleModel, LastVehiclePurchase, VehicleType, CurrPayment, MostImportantNewCar, Marketing) values ('$FName', '$LName', '$StreetNum', '$StreetName', '$Zip', '$Telephone', '$Email', '$GuessNumber', '$DateOfSubmit', '$CurrVehicleYear', '$CurrVehicleMake', '$CurrVehicleModel', '$VehiclePurchase', '$CurrVehicleType', '$CurrPayment', '$MostImportantNewCar', '$Marketing')");
[Admin Edit: added some spaces to the SQL statement to allow it to wrap]
I have a connection to MySQL, because a previous query works fine. Here's the fields I have in the MySQL table, called CustomerEntry
CustomerEntryID, ClientSalesID, ClientNameID, FName, LName, StreetNum, StreetName, Zip, Telephone, Email, GuessNumber, GuessDate, CurrVehicleYr, CurrVehicleMake, CurrVehicleModel, LastVehiclePurchase, VehicleType, CurrPayment, MostImportantNewCar and Marketing
Do you see any typo? Nothing is inserted.