16. Calculating Disk Space : Space Requirements for Tables : Calculate Space Requirements for Heap Tables
 
Share this page                  
Calculate Space Requirements for Heap Tables
Note:  If rows in the table span pages, use the procedure in Calculate Space Requirements When Rows Span Pages (see page Calculate Space Requirements When Rows Span Pages) instead.
Use the following procedure to determine the amount of space needed to store the data in a heap table:
1. Create the table.
2. Determine the number of rows that fit on a page.
select tups_per_page from iitables where table_name = ‘tablename’;
3. Determine the total number of pages needed if the table is a heap.
total_heap_pages = num_rows / tups_per_page