rgb192
asked on
how can I modify table structure to make this query run
CREATE TABLE `renters` (
`id` int(11) NOT NULL auto_increment,
`first_name` varchar(100) default NULL,
`last_name` varchar(100) default NULL,
`email1` varchar(100) default NULL,
`email2` varchar(100) default NULL,
`email3` varchar(100) default NULL,
`phone1` varchar(20) default NULL,
`phone2` varchar(20) default NULL,
`phone3` varchar(20) default NULL,
`information` varchar(4000) default NULL,
`description` varchar(9000) default NULL,
PRIMARY KEY (`id`),
UNIQUE KEY `email1` (`email1`)
) ENGINE=MyISAM AUTO_INCREMENT=32 DEFAULT CHARSET=utf8$$
INSERT INTO renters (first_name,last_name,emai l1,email2, email3,pho ne1,phone2 ,phone3,in formation, descriptio n) VALUES ('test','','derrickjmiller 1@gmail.co m','','',' ','','','' ,'') ON DUPLICATE KEY UPDATE renters set description=concat(descrip tion,'somt hing to add to description')
Error Code: 1064. 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 'set description=concat(descrip tion,'somt hing to add to description')' at line 1
how can I modify table structure to make this query run
to add to column description in that row where email1 is there
`id` int(11) NOT NULL auto_increment,
`first_name` varchar(100) default NULL,
`last_name` varchar(100) default NULL,
`email1` varchar(100) default NULL,
`email2` varchar(100) default NULL,
`email3` varchar(100) default NULL,
`phone1` varchar(20) default NULL,
`phone2` varchar(20) default NULL,
`phone3` varchar(20) default NULL,
`information` varchar(4000) default NULL,
`description` varchar(9000) default NULL,
PRIMARY KEY (`id`),
UNIQUE KEY `email1` (`email1`)
) ENGINE=MyISAM AUTO_INCREMENT=32 DEFAULT CHARSET=utf8$$
INSERT INTO renters (first_name,last_name,emai
Error Code: 1064. 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 'set description=concat(descrip
how can I modify table structure to make this query run
to add to column description in that row where email1 is there
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
works
and
my query had too many words
and thanks for the link