Notice
														
												
											
												
												
													Recent Posts
													
											
												
												
													Recent Comments
													
											
												
												
													Link
													
											
									| 일 | 월 | 화 | 수 | 목 | 금 | 토 | 
|---|---|---|---|---|---|---|
| 1 | 2 | 3 | 4 | |||
| 5 | 6 | 7 | 8 | 9 | 10 | 11 | 
| 12 | 13 | 14 | 15 | 16 | 17 | 18 | 
| 19 | 20 | 21 | 22 | 23 | 24 | 25 | 
| 26 | 27 | 28 | 29 | 30 | 31 | 
													Tags
													
											
												
												- ASP
- MS-SQL
- pandas
- urllib
- python
- MySQL
- node.js
- flutter
- swift
- mssql
- PER
- Unity
- 라즈베리파이
- 다이어트
- PyQt5
- tensorflow
- 맛집
- Linux
- 날짜
- Excel
- GIT
- 함수
- port
- 리눅스
- javascript
- 유니티
- ubuntu
- PyQt
- sqlite
- IOS
													Archives
													
											
											
											
											아미(아름다운미소)
Postgres: Show Schema Sizes in a Database 본문
SELECT schema_name,
    pg_size_pretty(sum(table_size)::bigint) as "disk space",
    (sum(table_size) / pg_database_size(current_database())) * 100
        as "percent"
FROM (
      SELECT pg_catalog.pg_namespace.nspname as schema_name,
          pg_relation_size(pg_catalog.pg_class.oid) as table_size
      FROM   pg_catalog.pg_class
          JOIN pg_catalog.pg_namespace
              ON relnamespace = pg_catalog.pg_namespace.oid
) t
GROUP BY schema_name
ORDER BY schema_namePostgres: 데이터베이스의 스키마 크기 표시
'데이타베이스' 카테고리의 다른 글
| oracle Procedure 내용조회 (0) | 2025.05.07 | 
|---|---|
| Postgresql timezone 변경 (0) | 2021.12.18 | 
| [SQL] SQLGate 키보드 단축키 (0) | 2018.03.09 | 
			  Comments