Posts
463
Comments
319
Trackbacks
1
T-SQL: Can you alter multiple columns within a single alter table statement?

No.  You can add multiple columns, but you have to use a separate alter table statement for each column you want to alter.

posted on Monday, May 09, 2005 1:55 PM Print
Comments
# re: T-SQL: Can you alter multiple columns within a single alter table statement?
x002548
5/6/2008 12:30 PM
Are you smoking something?

http://weblogs.sqlteam.com/brettk/category/72.aspx
Gravatar
# re: T-SQL: Can you alter multiple columns within a single alter table statement?
jdn
5/6/2008 1:08 PM
Sorry, but your link has to do with updating multiple tables within an update statement.

I'm talking about altering multiple columns within a single alter table statement.
# re: T-SQL: Can you alter multiple columns within a single alter table statement?
Major Singh
5/22/2008 3:51 AM
Yes, You can Add multiple columns with s single alter statement. The statement will be..
ALTER TABLE TABLENAME
ADD TEST1 varchar(100) NULL,
TEST2 varchar(100) NULL,
TEST3 varchar(100) NULL

Gravatar
# re: T-SQL: Can you alter multiple columns within a single alter table statement?
jdn
5/22/2008 6:23 PM
No, again, I'm talking about altering multiple columns within a single alter statement.

You are talking about adding them. Different thing.
Gravatar
# re: T-SQL: Can you alter multiple columns within a single alter table statement?
Dercsár
8/26/2008 4:09 AM
jdn is right. You can not modify multiple columns in one statement, which is weird imo.

Post Comment

Title *
Name *
Email
Url
Comment *  
Please add 5 and 3 and type the answer here: