Hi all,
There is a diag CLI command which helps with this a lot. You will need admin rights to be able to run it.
im diag --diag=viewallobjectsforsession on
After running this command, you will be able to see every query, report, chart, dashboard, etc even if the user did not explicitly share it with you. This only grants read access, if you need to modify anything (such as share a query belonging to a user that left the company to their replacement) you can copy the old query and modify the copy.
All of the queries/reports/charts/dashboards will show up in your client UI as well as in the CLI, so to get to the list of query definitions, you'll want to run a different CLI command after the diag (and pipe the output to a file).
im queries --fields=createdBy,name,queryDefinition
Unfortunately this is not possible to do from the SQL backend as the query definitions are stored in a column with other query metadata in a binary format and can't really be queried against.
As an alternate approach if you have only a few fields/types/states that you need to check, you can always look at the "References" tab of the particular admin object in the Admin Client and it will populate a list of everything (admin and regular user) that references that object, including queries, reports, charts, etc. The references view can be a bit slow and is probably not as useful as extracting the query definitions themselves, but it is very useful if you just need a quick way to see everything that could be impacted if you change a particular field or type.
Hope that helps,
Matt