Query Plex Database to tie Account to Library

I have many of my family members on Plex. As my server has grown, I’ve added libraries. I just realized I forgot to add 1 library to 1 family member. I have nearly 50 accounts on my server, so it’s not time friendly to open each one.

I would like to write a query in the database to find out which users are allowed to access which library.

I know the accounts are in table ‘accounts’
I know the libraries are in table ‘library_sections’

How can I tie ‘accounts’ to ‘library_sections’? I’ve checked every table in the database, and none of them appear to be the cross reference that I need?

They are not stored there. I mean, if you do a clean OS install and then install plex on top, you will find all of your family and friends listed with all the shared folders. That’s from a clean(no database) install. And to be honest, being hosted online makes a bit of sense if you think about how remote users connect to you, more or less they get authenticated thru plex.tv.
So plex.tv will have to know your share permissions to even allow connections to you.

I totally understand that Plex.TV will store authentication data, but I would have expected my local system would tie an account to a library? I would not have expected Plex.TV to store the cross reference between account and library.

What I am really trying to do, is look up users/accounts by library. I know I can see what a user has access to by looking at the user, but I really wanted to look at a particular library, and find out who all has access to it.

Accounts don’t exist until it hits plex.tv.

It just doesn’t exist yet. What you ask for is a nice idea though! A “detail” list of libraries to include all folders associated with and users associated with.

But… at the moment it’s just not there.

Thanks! That explains why I can’t figure out how to do it. Greatly appreciate your response.