Created
July 14, 2014 20:06
-
-
Save JamesSkemp/ab3408f4618d1f98e8a8 to your computer and use it in GitHub Desktop.
Find Sitecore users with an Administrator Flag (may return some false positives)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// query against XXX_Sitecore_Core | |
var adminUsers = from profile in Aspnet_Profiles | |
join user in Aspnet_Users on profile.UserId equals user.UserId | |
where profile.PropertyNames.Contains("Administrator") | |
&& profile.PropertyValuesString.Contains("True") | |
select new { Profile = profile, User = user } | |
; | |
adminUsers | |
.OrderBy (u => u.User.LastActivityDate) | |
.Dump(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment