add new column in sql table with default value nulll code example
Example 1: add column table sql default value
ALTER TABLE users
ADD visit_number INT DEFAULT 0;
Example 2: Add a column with a default value to an existing table in SQL Server
ALTER TABLE {TABLENAME}
ADD {COLUMNNAME} {TYPE} {NULL|NOT NULL}
CONSTRAINT {CONSTRAINT_NAME} DEFAULT {DEFAULT_VALUE}
WITH VALUES