Sam OZ
asked on
Table creation in non dbo schema
Hi,
I work with Sql server 2016 . While creating a table it is getting created in the DBO schama and I have no option to change . How can I create a table in a different schema?
I work with Sql server 2016 . While creating a table it is getting created in the DBO schama and I have no option to change . How can I create a table in a different schema?
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
When creating an object in SQL Server, the object will be created in the default user schema if no explicit schema has been provided.
To create an object in a different database schema you'll need to explicitly say the schema name, as provided above by Nitin. Mind that the user need to have permissions to create objects in the desired schema.
To create an object in a different database schema you'll need to explicitly say the schema name, as provided above by Nitin. Mind that the user need to have permissions to create objects in the desired schema.
You also have to create the schema first.
Open in new window