sntiwary
Hall of Fame
Points: 3475
More actions
September 29, 2003 at 4:17 am
#151937
How to generate list of logins with their defaut database in a sqlserver?
paul_richardson
SSCarpal Tunnel
Points: 4594
September 29, 2003 at 4:45 am
#476159
hi,
use :-
select name, dbname from master..syslogins
order by name
see syslogins in BOL
HTH
Paul
Greg Milner
SSCrazy
Points: 2425
September 30, 2003 at 9:06 am
#476387
Also and FYI:
There's a great script called sp_help_revlogin (by Gregory A. Larsen) which copies all your server logins to another script you can use to recreate them on another server. Here's the link.
http://www.databasejournal.com/features/mssql/article.php/2228611
G. Milner
rstone
SSCertifiable
Points: 6209
September 30, 2003 at 11:07 am
#476412
There is also sp_helplogins.
RandyHelpdesk: Perhaps Im not the only one that does not know what you are doing. 😉
Viewing 4 posts - 1 through 3 (of 3 total)
You must be logged in to reply to this topic. Login to reply