I wish to duplicate a table without contents (values) but keeping primary key and all the constraints.
The following code will only copy the columns' names but the primary key and constraints are missed:
SELECT TOP(0) * INTO new_table FROM source_table;
And this code will gives error about the "LIKE" syntax:
CREATE TABLE new_table LIKE source_table;
I wish to do it with a query/code, not with mouse and settings of Microsoft SQL Management Studio.