Measuring table sizes per solutions
ITMS 8.x
How do I determine what the database table sizes are in the Altiris database per solution?
You can run the following SQL script in SQL Management Studio to determine which tables are the largest:
-- Approx table size count
select
[Table] = so.[name]
,[Rows] = max(si.[rows])
,[Index Pages] = max(si.[dpages])
,[Reserved] = max(si.[reserved])
,[Used] = max(si.[used])
from sys.objects so
join sysindexes si on si.id = object_id(so.[name])
where so.[type] = 'U' and si.[rows] > 0
group by so.[name]
order by 2 desc