Files
DBAdmin/inbox/DataBase/PostgreSQL/tablespace/tbsp_info.sql
T
2026-05-18 06:40:19 +00:00

28 lines
490 B
SQL

VIEW TABLESPACE INFO IN POSTGRES:
postgres=# select * from pg_tablespace;
(OR)
postgres=# \db+
(or)
-- For getting size of specific tablespace:
postgres=# select pg_size_pretty(pg_tablespace_size('ts_dbaclass'));
pg_size_pretty
----------------
96 bytes
(1 row)
Pre-configured tablespaces:( these are default tablespaces)
Pg_global - > PGDATA/global - > used for cluster wide table and system catalog
Pg_default - > PGDATA/base directory - > it stores databases and relations