Where is information about users associated with specific SharePoint site stored?
I guess information is stored in relational database.
To be more specific i want to ask if it is possible to query this database and get list of all users which have access to site mysubdomain.mydomain.com/sites/xyz where xyz is set of sites and to complicate it more, there is also abc which represents sub-sites which have different set of members and visitors group and there is also another group with different permission level.
As example lets have mysubdomain.mydomain.com/sites/aaa/bb and than mysubdomain.mydomain.com/sites/aaa/cc and this two sub sites have different set of user. So to summarize my question. I want to get as result of SQL query table with username (NT\login) with information about sites/sub-site and permission level.
My question is: Is this possible? Another question: Is there any method how to get this information without installing anything on server side of SharePoint farm? I have list of sites and sub-sites with URL's.
More details:
Let me describe one solution I have now. I’ve found tool Data Juggler (http://www.djuggler.com/) which can automate repetitive web tasks. This means that I’ve prepared list of all sites/sub-sites in my scope. As a source I use spreadsheet with all details about sites/sub-sites input.xlsx this is only one part of process maintained manually. It was big effort to take all data together, but once this was done, it is easier to maintain, as new sites/sub-sites are created occasionally Information in this spreadsheet are in this order:
- URL to Members group (users with Read/Write access)
- URL to Visitors group (users with Read Only access)
- REGION
- Site/Sub-site URL
- Site Name
- Sub-site Name
- Site owner
Ok that’s introduction, now how it works:
- After loading scrip to Djuggler it pops up a window asking you to browse to input spreadsheet (input.xlsx)
- Then it pops up window asking you for number of records in spreadsheet (this step could be possibly omitted if I will tweak the script, but I made this solution in one night learning from examples and building script)
- After that it loads all the information from spreadsheet to Djuggler’s temporary grid and start loading values from columns to variables
- First it loads URL to Members group and rest of columns except URL to Visitors group and uses its internal browser to load page from URL to Members group
- Application start searching in html source of loaded site and looking for specific html tags
account=”something”
andemail=”something”
and stores something into variable, than store new row into another grid with all details Account, Email, REGION, Site/Sub-site URL, Site Name, Sub-site Name, Site owner and loops through whole html source, than it jump in loop to another URL to Members group and loops again trough html source and this continue, till loop trough URL to Members group will run for x times, where x is number of rows submitted in second step - After this loop jump to second column with URL to Visitors group and whole process with loops is repeated.
- At the end application store temporary grid with results from loops into spreadsheet and opens this spreadsheet.
I know that email address and NT\login is pretty the same information so email could be omitted to avoid redundancy of information. And rest of information like region, site name, sub-site name and site owner could be added in second step. For me it is more logical to have just information pulled from site Site/sub-site URL, NT\login of user and permission level (contribute, read, …) So for now I have some solution, but it is “like scraping your head behind left ear with right hand from back of your head…” I am looking for something more elegant.