March 7, 2014 at 10:28 am
I have sysadmin access to the sql server, long time back i created SQL User called DB_SQL and I created some table which was created DB_SQL.table1. Now I want to create some more table and I forget the password. The problem is we cannot change the password.
Is there any way I can create table with DB_SQL.Table_new. since all the new tables is getting created by default dbo.all_tables
March 7, 2014 at 10:36 am
When you specify the schame name in the CREATE command, the table will be created in the mentioned schema
CREATE TABLE [DB_SQL].[table_new] (column datatype, ....)
March 7, 2014 at 10:38 am
create table DB_SQL.Table_new(col definitions)
or you could create the dbo table and do this:
alter schema DB_SQL transfer dbo.Table_new
March 7, 2014 at 10:39 am
Thanks Can I rename the table which has a DBO.Tablename as DB_SQL.Tablename
March 7, 2014 at 10:41 am
no, but you can do this:
alter schema DB_SQL transfer dbo.Tablename
March 7, 2014 at 10:45 am
Thanks everyone it was a great help
Viewing 6 posts - 1 through 6 (of 6 total)
You must be logged in to reply to this topic. Login to reply