Last active
January 19, 2021 04:02
-
-
Save HainanZhao/3e1192ade21592d8975edddace9a1fa6 to your computer and use it in GitHub Desktop.
Sybase SQL Anywhere check Data, DB File, Log File size
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--Table Size | |
SELECT sum((((table_page_count * DB_PROPERTY('PageSize')) / 1024) / 1024)) as TableSize FROM SYSTAB | |
--DB File Size | |
SELECT db_property('filesize') * DB_PROPERTY('PageSize') / 1024 / 1024 as FileSize | |
--Log File Size | |
select db_extended_property('FileSize', 'TransLog') * db_property('PageSize') / 1024 / 1024 as LogSize | |
--Reference | |
--http://dcx.sap.com/index.html#sqla170/en/html/81f67d7b6ce21014b742d395f1fcfac5.html |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment