Find Byte Size of Tables in Database

This blog explains how to retrieve the byte sizes of tables that are present in current database. Use Below query to find out the size of tables.
 
Query:

  1. SELECT sob.name AS Table_Name,  
  2.   
  3. SUM(sys.length) AS [Size_Table(Bytes)]  
  4.   
  5. FROM sysobjects sob, syscolumns sys  
  6.   
  7. WHERE sob.xtype='u' AND sys.id=sob.id  
  8.   
  9. GROUP BY sob.name  
Result: