June 14, 2012 at 1:53 am
I want t-sql statement for setting default user
at the time of creating database in sql server.
June 14, 2012 at 2:21 am
sej2008 (6/14/2012)
I want t-sql statement for setting default userat the time of creating database in sql server.
You can use...
Exec sp_defaultdb @loginame='login', @defdb='database name'
June 14, 2012 at 9:06 am
ganeshnarim (6/14/2012)
sej2008 (6/14/2012)
I want t-sql statement for setting default userat the time of creating database in sql server.
You can use...
Exec sp_defaultdb @loginame='login', @defdb='database name'
I'd be curious to know if this actually answered the OP question...
What do you mean by "setting default user"?
June 15, 2012 at 11:29 pm
I am sorry the sp that u sent is not working.
I want to set default user at the creating database.
June 16, 2012 at 12:09 am
A database doesn't have a default user.
The way to create a user is the CREATE USER command.
CREATE USER someDatabaseUser FOR LOGIN someServerLogin;
Nothing default about it.
Viewing 5 posts - 1 through 4 (of 4 total)
You must be logged in to reply to this topic. Login to reply