<http://www.mysql.com/doc/en/ALTER_TABLE.html> states that:

You can issue multiple ADD, ALTER, DROP, and CHANGE clauses in a single ALTER TABLE statement. This is a MySQL extension to SQL-92, which allows only one of each clause per ALTER TABLE statement.

but it doesn't give the syntax for doing so.

Maybe try:

ALTER TABLE tmp DROP COLUMN col_1 DROP COLUMN col_2...;?

-Cameron Wilhelm


On Tuesday, August 12, 2003, at 07:22 PM, Adam Fortuno wrote:


Was in the midst of doing something today and I attempted to drop a number of columns in a table with the following:

ALTER TABLE tmp DROP COLUMN col_1, col_2, col_3, col_4;

Unfortunately MySQL gave me an error reading:

ERROR 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 'col_2, col_3, col_4' at line 1

Can you not have multiple columns names in an alter statement?


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





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



Reply via email to