![]() |
|
|
|
#1 |
|
Guest
Posts: n/a
|
SQL 2005, changing VARCHAR column size
Management Studio allows to change the column size easy way.
It's instant so I think there is no ADD, DROP, UPDATE etc commands in the background. Is there a single SQL command that can resize (increase) VARCHAR column? Thanks, MH |
|
|
#2 |
|
Guest
Posts: n/a
|
Re: SQL 2005, changing VARCHAR column size
ALTER TABLE ... ATLER COLUMN...
Above is an instance operation for some type of modifications (like increasing size of varchar). -- Tibor Karaszi, SQL Server MVP http://www.karaszi.com/sqlserver/default.asp http://sqlblog.com/blogs/tibor_karaszi "Marius Horak" <nobody@eu.con> wrote in message news:%233rMbW$DIHA.5228@TK2MSFTNGP05.phx.gbl... > Management Studio allows to change the column size easy way. > It's instant so I think there is no ADD, DROP, UPDATE etc commands in > the background. > > Is there a single SQL command that can resize (increase) VARCHAR column? > > Thanks, > > MH |
|
|
#3 |
|
Guest
Posts: n/a
|
Re: SQL 2005, changing VARCHAR column size
Tibor Karaszi wrote:
> ALTER TABLE ... ATLER COLUMN... > > Above is an instance operation for some type of modifications (like > increasing size of varchar). Thank you. It works. But why BOL does not show such option? One pays M$ zillions of dollars and gets old help info. ALTER TABLE table_name { [ ALTER COLUMN column_name {DROP DEFAULT | SET DEFAULT constant_expression | IDENTITY [ ( seed , increment ) ] } MH |
|
|
#4 |
|
Guest
Posts: n/a
|
Re: SQL 2005, changing VARCHAR column size
> But why BOL does not show such option?
Perhaps you wre looking in the "SQL Server Mobile" section? Here's what my Books Online say (ALTER TABLE): ALTER TABLE [ database_name . [ schema_name ] . | schema_name . ] table_name { ALTER COLUMN column_name { [ type_schema_name. ] type_name [ ( { precision [ , scale ] | max | xml_schema_collection } ) ] [ COLLATE collation_name ] [ NULL | NOT NULL ] -- Tibor Karaszi, SQL Server MVP http://www.karaszi.com/sqlserver/default.asp http://sqlblog.com/blogs/tibor_karaszi "Marius Horak" <nobody@eu.con> wrote in message news:uEEEYIJEIHA.536@TK2MSFTNGP06.phx.gbl... > Tibor Karaszi wrote: > >> ALTER TABLE ... ATLER COLUMN... >> >> Above is an instance operation for some type of modifications (like >> increasing size of varchar). > > Thank you. It works. > But why BOL does not show such option? > One pays M$ zillions of dollars and gets old help info. > > ALTER TABLE table_name > { [ ALTER COLUMN column_name > {DROP DEFAULT > | SET DEFAULT constant_expression > | IDENTITY [ ( seed , increment ) ] > } > > MH > |
| Thread Tools | |
| Display Modes | |
|
|
< Home - Windows Help - MS Office Help - Hardware Support >
| New To Site? | Need Help? |