Home » RDBMS Server » Server Administration » need to calculate average_row length for table
need to calculate average_row length for table [message #62405] Tue, 20 July 2004 12:42 Go to next message
Joan
Messages: 36
Registered: February 2002
Member
I need to calculate average row length for my database and was kind of curious to what is best way.

Eg. table aaaaa

   ID                                        NOT NULL NUMBER(19)
 NAME                                      NOT NULL VARCHAR2(64)
 INTERVAL                                           NUMBER(38)
 LASTMODIFIED                                       DATE

according to dba_tab_columns the data lengths for all data and number datatype is date -7 and number 22 regardless of what is define on the table.

Which number should I use to calculate the average row length?  the one on desc table or from dba_tab_columns.

Also what is best way to calculate the average row length.  I have used different formula with different resul

 

 
Re: need to calculate average_row length for table [message #62407 is a reply to message #62405] Tue, 20 July 2004 16:21 Go to previous message
andrew again
Messages: 2577
Registered: March 2000
Senior Member
select avg(
vsize(ID)+vsize(NAME)+(vsize(INTERVAL)+vsize(LASTMODIFIED))
from aaaa;
Previous Topic: version
Next Topic: unable to allocate MINEXTENTS beyond 1 in tablespace USERS
Goto Forum:
  


Current Time: Thu Jan 09 03:44:50 CST 2025