Click here to monitor SSC
SQLServerCentral is supported by Red Gate Software Ltd.
 
Log in  ::  Register  ::  Not logged in
 
 
 
        
Home       Members    Calendar    Who's On


Add to briefcase

query to find Inactive users in SQL server Expand / Collapse
Author
Message
Posted Tuesday, December 10, 2013 7:15 AM
Grasshopper

GrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopper

Group: General Forum Members
Last Login: Monday, March 17, 2014 3:56 AM
Points: 14, Visits: 64
Hi,

Could any1 help me how to find inactive users(e.g users who have not logged in for a long time) in SQL server???
Post #1521511
Posted Tuesday, December 10, 2013 7:35 AM


Ten Centuries

Ten CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen Centuries

Group: General Forum Members
Last Login: Wednesday, April 02, 2014 6:12 AM
Points: 1,275, Visits: 661
SELECT name,accdate FROM master.dbo.syslogins

http://technet.microsoft.com/en-us/library/ms178593.aspx
Post #1521517
Posted Tuesday, December 10, 2013 7:38 AM
Grasshopper

GrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopper

Group: General Forum Members
Last Login: Monday, March 17, 2014 3:56 AM
Points: 14, Visits: 64
SELECT name,accdate FROM master.dbo.syslogins

shows the creation date but i want the last login date when the user logged in for the last time
Post #1521518
Posted Tuesday, December 10, 2013 7:47 AM


SSC-Forever

SSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-Forever

Group: General Forum Members
Last Login: Today @ 11:52 AM
Points: 41,530, Visits: 34,446
SQL doesn't track that automatically. You'll need custom auditing for that.


Gail Shaw
Microsoft Certified Master: SQL Server 2008, MVP
SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

We walk in the dark places no others will enter
We stand on the bridge and no one may pass

Post #1521526
« Prev Topic | Next Topic »

Add to briefcase

Permissions Expand / Collapse