Post

Getting size of a table in Azure SQL Database

1
2
3
4
5
6
7
8
9
10
select
    obj.name,
    sum(reserved_page_count) * 8.0 as "size in KB"
from
    sys.dm_db_partition_stats part,
    sys.objects obj
where
    part.object_id = obj.object_id
group by
    obj.name

Ref.

This post is licensed under CC BY 4.0 by the author.