Answers for "set default 2 column value in sql server"

SQL
1

How to Add a Default Value to a Column in MS SQL Server

ALTER TABLE <table_name> ADD DEFAULT <DEFAULT_VALUE> FOR <NAME_OF_COLUMN>
Posted by: Guest on March-26-2021
0

default column value in sql same as other column

ALTER TABLE tablename ADD newcolumn type NOT NULL DEFAULT (0)
Go
Update tablename SET newcolumn = oldcolumn Where newcolumn = 0
Go
Posted by: Guest on December-11-2020

Code answers related to "set default 2 column value in sql server"

Code answers related to "SQL"

Browse Popular Code Answers by Language