• Yes, you can query the system tables to get data about the database objects. Here's how to get the schema for all user-defined tables in your database.

    select ss.name, so.name

    from sys.schemas ss

    inner join sys.objects so on so.schema_id = ss.schema_id

    where so.type = 'u'

    order by ss.name, so.name;