0

Hello Good People

I have this error message....Parse error: syntax error, unexpected T_STRING in on line 111 ($result = mysql_query(" insert into users_cv )


this is the script line wherei have it

// SELECT DATABASE
mysql_select_db($database_recruit) or die(mysql_error());
$result = mysql_query(" insert into users_cv
SET
title = '$title',
firstname = '$firstname',
middlename = '$middlename',
surname = '$surname',
priornames = '$priornames'
reasons = '$reasons',
birthplace = '$birthplace',
dob_month = '$dob_month',
dob_day = '$dob_day',
dob_year = '$dob_year',
sex = '$sex',
nigeria_address = '$nigeria_address',
state_of_origin = '$state_of_origin',
lga = '$lga',
current_address = '$current_address',
contact_details = '$contact_details',
phone = '$phone',
fax = '$fax',
occupation = '$occupation',
identification = '$identification',
eyes = '$eyes',
hair = '$hair',
special_features = '$special_features',
marital_status = '$marital_status',
kinname = '$kinname',
kin_address = '$kin_address',
kin_relationship = '$kin_relationship',
date_posted = '$date_posted',
resume = '$resume' ") or die(mysql_error());
//


please can anyone help me with this?
thanks

3
Contributors
5
Replies
6
Views
6 Years
Discussion Span
Last Post by pritaeas
0

Can't see a string termination failure, unless one of your variables contain a double quote. Next to that, the syntax of your insert query is wrong. (Learn to use code tags)

Edited by pritaeas: n/a

0

hello,ptriteas,

what is the correct syntax please?
i am not a guru on this,can you also tell me how to use code tags/

thanks

0

Erro code is on line 5 please can you help me with this good people?

//print_r($_SESSION);

// SELECT DATABASE
mysql_select_db($database_recruit) or die(mysql_error());
$result = mysql_query(" insert into users_cv 
SET
 title = '$title',
 firstname = '$firstname',
 middlename = '$middlename',
 surname = '$surname',					  
 priornames = '$priornames'
 reasons = '$reasons',
 birthplace = '$birthplace',				  
 dob_month = '$dob_month',					  
 dob_day = '$dob_day',					  
 dob_year = '$dob_year',
 sex = '$sex',
 nigeria_address = '$nigeria_address',
 state_of_origin = '$state_of_origin',
 lga = '$lga',	
 current_address = '$current_address',
 contact_details = '$contact_details',
 phone = '$phone',	
 fax = '$fax',
 occupation = '$occupation',
 identification = '$identification',			  					  					  
 eyes = '$eyes',					  
 hair = '$hair',					  
 special_features = '$special_features',					  
 marital_status = '$marital_status',
 kinname = '$kinname',					  
 kin_address = '$kin_address',					  
 kin_relationship = '$kin_relationship', 	
 date_posted = '$date_posted',				  					  
 resume = '$resume' ") or die(mysql_error());
//

Edited by bluetoot: n/a

0

Hi bluetoot;
first u have mysql error into your insert statement

INSERT INTO users_cv 
VALUES(yourVaues,..,..,..);

second the error is produced because one or more of ur variable produce "" after linkin there values so check wat u pass to the statement

good luck

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.