1
I need to raise users of an instance that no longer exist in the AD for cleaning these. Is there any way to compare AD users with windows Authentication users of an SQL instance?
1
I need to raise users of an instance that no longer exist in the AD for cleaning these. Is there any way to compare AD users with windows Authentication users of an SQL instance?
0
Hello @rafaabell, you can use the stored system processor sp_validatelogins
to display the logins of Windows employees who no longer exist and still remain in the SQL Server instance.
EXEC sp_validatelogins;
GO
Rodrigo thank you so much! It was exactly what I needed.
I’m glad I helped. I could mark my answer as useful and your question as answered?
Browser other questions tagged sql database sql-server windows ad
You are not signed in. Login or sign up in order to post.
Your question seems to me very generic and speculative. I could edit it and provide a minimum and verifiable example?
– Rodrigo Nascentes
Hello Rodrigo, I will complement the doubt... I have an instance that has several logins of employees who are no longer working in the company, for audit purposes I need to revoke those logins that no longer exist in AD but which remain with your existing Windows Authentication users in the instance, then I wonder if there is a way to connect in AD and make this comparison query without needing Linked server.
– rafaabell