adding a mysql query as text into a history table... ?
| From: | Gawie Marais | Date: | Wed, 23 Jun 2004 09:14:21 +0000 |
| Subject: | adding a mysql query as text into a history table... ? | ||
| Groups: | php.db | ||
| Request: | Send a blank email to php-db+get-34884@lists.php.net to get a copy of this message | ||
hi guys,
i have created a 'history' table and would like to insert the 'bare' sql
query into that table just to check who did what on the database...
now, i have this :-
$CustUpdate = "INSERT INTO record SET
recid = '',
customer_code = '$varCustomerCode',
id_reg = '$varId_Reg',
date_added = '$getCurrentDate',
date_modified = '0000-00-00 00:00:00',
date_closed = '0000-00-00 00:00:00',
technician = '$varConsultant',
flag = '$flag',
contact_person = '$varContactPerson',
contact_number = '$varContactNumber',
contact_email = '$varContactEmail',
problem_type = '$varProblemType',
problem_description = '$varProblemDescription',
priority = '$varPriority',
technical_feedback = '',
customer_name = '$varCustomerName'
";
i would like to add the whole query into a text field in the 'history'
table, but i get errors when i try to add it... can anyone help ?
this is the error :-
Invalid query: You have an error in your SQL syntax near '2004-06-23
11:09:57', date_modified = '0000-00-00 00:00:00', date_closed =' at line 6