How to describe table in SQL Server 2008?

前端 未结 8 1514
长情又很酷
长情又很酷 2020-12-24 05:33

I want to describe a table in SQL Server 2008 like what we can do with the DESC command in Oracle.

I have table [EX].[dbo].[EMP_MAST] which

8条回答
  •  庸人自扰
    2020-12-24 05:44

    The sp_help built-in procedure is the SQL Server's closest thing to Oracle's DESC function IMHO

    sp_help MyTable
    

    Use

    sp_help "[SchemaName].[TableName]" 
    

    or

    sp_help "[InstanceName].[SchemaName].[TableName]"
    

    in case you need to qualify the table name further

提交回复
热议问题