Forum Discussion
QUESTION::LAKEHOUSE::SQL ENDPOINT::SYSTEM VIEWS
- Anonymous1 year ago
Hi Element115 ,
Run the following two commands in Notebook to calculate the table size in lakehouse.
The first command contains the table size in byte, my table is smaller, replace the products table with your own when using it.
%%sql DESCRIBE DETAIL delta.`Tables/products`The second command converts byte to GB, replacing 3213 with your own after running the first command.
size_in_bytes = 3213 # byte swtich GB size_in_gb = size_in_bytes / (1024 ** 3) print(f “Table ‘products’ size: {size_in_gb:.8f} GB”)Best Regards,
Yang
Community Support TeamIf there is any post helps, then please consider Accept it as the solution to help the other members find it more quickly.
If I misunderstand your needs or you still have problems on it, please feel free to let us know. Thanks a lot!
Anonymous
1__Are ALL the systeme views, including those in INFORMATION_SCHEMA, available for query if you have a paying SKU?
2__If my user has admin priv, will there still be some restriction?
Hi Element115 ,
Some views are used internally for system operations and development purposes, and they might not be exposed for direct querying regardless of your license type or administrative privileges.
Just because a view is listed doesn’t mean it’s queryable.
Some views are for internal system use and not meant for direct access.
While a paid SKU and admin privileges generally provide broader access, they don’t guarantee visibility of all system views.
Best Regards,
Yang
Community Support Team
If there is any post helps, then please consider Accept it as the solution to help the other members find it more quickly.
If I misunderstand your needs or you still have problems on it, please feel free to let us know. Thanks a lot!
- Element1151 year agoMemorable Member
OK so what is the best way to find the total size in GB of one or more tables if we cannot query system views?
- Anonymous1 year agoNot applicable
Hi Element115 ,
Run the following two commands in Notebook to calculate the table size in lakehouse.
The first command contains the table size in byte, my table is smaller, replace the products table with your own when using it.
%%sql DESCRIBE DETAIL delta.`Tables/products`The second command converts byte to GB, replacing 3213 with your own after running the first command.
size_in_bytes = 3213 # byte swtich GB size_in_gb = size_in_bytes / (1024 ** 3) print(f “Table ‘products’ size: {size_in_gb:.8f} GB”)Best Regards,
Yang
Community Support TeamIf there is any post helps, then please consider Accept it as the solution to help the other members find it more quickly.
If I misunderstand your needs or you still have problems on it, please feel free to let us know. Thanks a lot!