本文介绍了如何获取postgresql中的表总数?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
有没有什么方法可以获得一个Postgresql数据库中的表总数?我使用的postgresql版本是PostgreSQL 8.4.14。
Is there any way by which I can get the total number of tables in a Postgresql database? The postgresql version I'm using is PostgreSQL 8.4.14.
推荐答案select count(*) from information_schema.tables;
或者,如果您想查找仅适用于特定模式的表数:
Or if you want to find the number of tables only for a specific schema:
select count(*) from information_schema.tables where table_schema = 'public';更多推荐
如何获取postgresql中的表总数?
发布评论