October 1, 2009 at 7:15 pm
When I open SSMS and login through Authentication to a server, is there a way to make it default to a particular database other than 'master'.?
Dan
October 1, 2009 at 8:34 pm
First thought is change the default database for your login to something other than master.. Try that..
CEWII
October 2, 2009 at 6:10 am
You could use the command line switches of SSMS/SQLWB
Ssms.exe|SQLWB.exe [-S servername] [-d databasename] [-U login] [-P password] [-E] [-nosplash] [file_name[,file_name]]
-S [servername] server name to connect to
-d [databasename] nome of the database
-U [loginname] SQL Server login
-P [password] SQL Server login's password
-E Use Windows Authetication
[file_name] SQL file to open
-- Gianluca Sartori
October 2, 2009 at 7:20 am
CEWII
I login in through Win Authen; so I do not see my login in under Security->Logins
Dan
October 2, 2009 at 7:23 am
Gianluca Sartori
That worked. thx.
Dan
October 2, 2009 at 7:35 am
repent_kog_is_near (10/2/2009)
CEWIII login in through Win Authen; so I do not see my login in under Security->Logins
Dan
Then you would have to change it for the whole group that is allowing you in.. The other poster's idea is better in that case..
CEWII
October 2, 2009 at 6:46 pm
CEWII
Thanks very much for your thought there. In the Servers where I have specific login under security, I will use your method.
Dan.
October 2, 2009 at 8:08 pm
Another option would be to set the database you want to connect to in the Registered Servers portion of SSMS. Then, every time you want to open a new query - right click on the registered server and select new query.
If you double-click on the entry in registered servers, then select that server in Object Explorer - new query windows will also open up in the defined database.
Jeffrey Williams
“We are all faced with a series of great opportunities brilliantly disguised as impossible situations.”
― Charles R. Swindoll
How to post questions to get better answers faster
Managing Transaction Logs
October 3, 2009 at 7:22 pm
Ahh! I have never used registered server window before. Now, I see I have missed a good functionality of SSMS all this while.
thanks Jeff.
October 3, 2009 at 7:29 pm
You are welcome - glad I could help.
Jeffrey Williams
“We are all faced with a series of great opportunities brilliantly disguised as impossible situations.”
― Charles R. Swindoll
How to post questions to get better answers faster
Managing Transaction Logs
Viewing 10 posts - 1 through 9 (of 9 total)
You must be logged in to reply to this topic. Login to reply