資料表欄位屬性查詢,資料表欄位屬性

來源:互聯網
上載者:User

資料表欄位屬性查詢,資料表欄位屬性

---查詢資料庫所有表名
select id,name from sysobjects where xtype='u' order by name
---查詢表的所有欄位屬性
select   *  from   syscolumns   where   id=object_id(N'FMS_PayApply')
---查詢表欄位名,類型,長度,預設值,是否允許為空白
select column_name,data_type,CHARACTER_MAXIMUM_LENGTH,
COLUMN_DEFAULT ,IS_NULLABLE
 from information_schema.columns
where table_name = 'WF_WORKFLOW_STEP'

相關文章

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.