Skip to content
March 13, 2015 / doganay

AVERAGE TEMP SPACE NEEDED FOR A SQL

(num_rows * (key_length + 8)) * 1.2

Let’s say you have a table: table1

SQL> desc table1
COL1 VARCHAR2(3)
COL2 VARCHAR2(7)
our sql:
select * from table order by col1, col2;
num_rows=100.000
length_of_col1: 3
length_of_col2: 7
temp needed: 100.000*(3+7+8)*1.2~= 2 MB
Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: