CREATE OR REPLACE VIEW VIEW_PK AS
SELECT t.table_name 表名,t.column_name 主键列 FROM User_Cons_Columns t, User_Constraints t2
where t.constraint_name=t2.constraint_name and t.table_name=t2.table_name and t2.constraint_type='P'
Azure Lei Zhang的博客weibo: LeiZhang的微博/QQ: 185165016/QQ群:319036205/邮箱:leizhang1984@outlook.com/TeL:139-161-22926 |