文章詳情頁
DB2獲取當(dāng)前用戶表、字段、索引等詳細(xì)信息
瀏覽:236日期:2023-03-24 09:22:30
獲取所有表、字段、索引等詳細(xì)信息
SELECT d.name tbName, COALESCE(d.remarks, "") tbDesc, a.name columnName, a.coltype columnType , decode(a.nulls,"Y","1","0") notNull, decode(a.identity,"Y","1","0") auto, a.longlength width, a.scale precision, COALESCE(a.remarks, "") comment, decode(n.unique_colcount,"1","1","0") unique, decode(n.uniquerule,"P","1","0") masterKey, COALESCE(n.name, "") indexName FROM sysibm.syscolumns a INNER JOIN sysibm.systables d on a.tbname=d.name LEFT JOIN sysibm.sysindexes n on n.tbname=d.name and SUBSTR(colnames,2)=a.name where d.type="T"and d.tbspace="USERSPACE1"
標(biāo)簽:
DB2
上一條:DB2 數(shù)據(jù)庫創(chuàng)建、表的ixf文件導(dǎo)出導(dǎo)入示例下一條:DB2新手使用的一些小筆記:新建實(shí)例、數(shù)據(jù)庫路徑不存在、客戶端連接 .
相關(guān)文章:
1. mysql啟動(dòng)時(shí)報(bào)錯(cuò) ERROR! Manager of pid-file quit without2. mysql 數(shù)據(jù)庫優(yōu)化技巧3. 拋磚引玉,實(shí)例講解DB2中的表空間(1)4. mysql的like模式5. MySql關(guān)于null的函數(shù)使用分享6. MySQL 鎖的相關(guān)知識(shí)總結(jié)7. Oracle如何對CLOB行字段來執(zhí)行全文檢索8. DB2數(shù)據(jù)庫使用經(jīng)驗(yàn)漫談(1)9. 全球獲得Oracle認(rèn)證人數(shù)最新統(tǒng)計(jì)10. 詳解MySQL批量入庫的幾種方式
排行榜
