postgre查询表和记录数,查表字段


select relname as TABLE_NAME, reltuples as rowCounts from pg_class where relkind = 'r'
and relnamespace = (select oid from pg_namespace where nspname='public') order by rowCounts desc;

 

select * from information_schema.columns
where table_schema='public' and table_name='表名称 ';

 


免责声明!

本站转载的文章为个人学习借鉴使用,本站对版权不负任何法律责任。如果侵犯了您的隐私权益,请联系本站邮箱yoyou2525@163.com删除。



 
粤ICP备18138465号  © 2018-2025 CODEPRJ.COM