Re: Login/Account Lock
- From: Erland Sommarskog <esquel@xxxxxxxxxxxxx>
- Date: Wed, 11 Jul 2007 21:29:20 +0000 (UTC)
Venkatesh (Venkatesh@xxxxxxxxxxxxxxxxxxxxxxxxx) writes:
Thanks for the immediate response. But I think this will disable the
login - to disable the login we can very well use the below command
alter login [loginname] disable/enable
But what I want is to determine whether account is locked or not. When
you click the properties of a login in the status tab you would see the
account lock out check box. I want how programatically this can be
determined
Correct me If I am wrong. In case if your code
sys.server_principals.is_disabled is used to lock the account could you
give me an example.
OK, I admit that I took a gamble on that one.
It seems that Mohit did a better job on reading the manual that you and I
did.
--
Erland Sommarskog, SQL Server MVP, esquel@xxxxxxxxxxxxx
Books Online for SQL Server 2005 at
http://www.microsoft.com/technet/prodtechnol/sql/2005/downloads/books.mspx
Books Online for SQL Server 2000 at
http://www.microsoft.com/sql/prodinfo/previousversions/books.mspx
.
- References:
- Re: Login/Account Lock
- From: Erland Sommarskog
- Re: Login/Account Lock
- Prev by Date: Re: Assign permissions to allow updates but deny select on table
- Next by Date: Re: How can I see what permissions "VIEW SERVER STATE" has?
- Previous by thread: Re: Login/Account Lock
- Index(es):
Relevant Pages
|