Wednesday, October 3, 2012

List Schema Name and Table Name for Database

Script which generates all the tables in database along with its schema name.


SELECT '['+SCHEMA_NAME(schema_id)+'].['+name+']'
AS SchemaTable
FROM sys.tables

 

No comments:

Post a Comment