I think, there is an error in your syntax. (i am not sure)

After FROM, what do you want to call as a2 ??

INSERT INTO `answer` ( `answer` , `correct`,`qid` )  SELECT a2.`answer` , a2.`correct` 
, 3 FROM `answer` where a2.qid=0 

Vaso


-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
Sent: Wednesday, December 10, 2003 3:14 PM
To: [EMAIL PROTECTED]
Subject: copy from table to it again


i want to ask you a question 
    
i have a data in a table `answer` and i want to copy the data which
have a specific value in a filed and inserted into it again but i
will change the value 
   
i try to use this but it's give me an error 
 ======================= 
 INSERT INTO `answer` ( `answer` , `correct`,`qid` ) 
 SELECT a2.`answer` , a2.`correct` , 3 
 FROM `answer` as a2 where a2.qid=0 
=======================



--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:    http://lists.mysql.com/[EMAIL PROTECTED]

  • co... ابو ابراهيم
    • ... Gordon
    • Vasoczki Ferenc

Reply via email to