,

Query to get list of Schema and table name in Azure SQL database

Posted by

The query below lists all tables in an Azure SQL Database.

select schema_name(t.schema_id) as schema_name,
       t.name as table_name,
       t.create_date,
       t.modify_date
from sys.tables t
order by schema_name,
         table_name;

Columns

  • schema_name – name of the schema
  • table_name – name of the table
  • create_date – creation date of the table
  • modify_date – last modification date of the table by using an ALTER statement

Rows

  • One row: represents one table in the database
  • Scope of rows: all tables in the database
  • Ordered by: schema and table name

Sample results

guest
0 Comments
Inline Feedbacks
View all comments
0
Would love your thoughts, please comment.x
()
x