If you want max row size of the table, add up the total column widths.
If you want an average row size of a table, you can use the following
SQL which will generate a SQL statement to give you an average rowsize
for the table.
select 'round(avg(nvl(vsize('||column_name||'),0)),0) +'
from user_tab_columns
where table_name = 'your table name here'
...will give you a SQL statement of the form:
select round(avg(nvl(vsize(COLUMN_NAME_1),0)),0) +
round(avg(nvl(vsize(COLUMN_NAME_2),0)),0) +
round(avg(nvl(vsize(COLUMN_NAME_3),0)),0) +
round(avg(nvl(vsize(COLUMN_NAME_2),0)),0) "avg row size"
from 'table name'
where received_time_date between '01-NOV-2005' and '01-DEC-2005'; #
optional clause to limit rows used for calculation.
-----Original Message-----
From: Kumar Niraj
[mailto:oracledba-ezmlmshield-x33822005.[Email address protected]
Sent: Wednesday, June 28, 2006 11:53 AM
To: LazyDBA Discussion
Subject: Row size
How do we calculate rowsize of a table?
This e-mail and any attachments are confidential and intended solely
for the addressee and may also be privileged or exempt from disclosure
under applicable law. If you are not the addressee, or have received
this e-mail in error, please notify the sender immediately, delete it
from your system and do not copy, disclose or otherwise act upon any
part of this e-mail or its attachments..
Internet communications are not guaranteed to be secure or virus-free.
The Barclays Group does not accept responsibility for any loss arising
from unauthorised access to, or interference with, any Internet
communications by any third party, or from the transmission of any
viruses. Replies to this e-mail may be monitored by the Barclays
Group for operational or business reasons..
Any opinion or other information in this e-mail or its attachments
that does not relate to the business of the Barclays Group is personal
to the sender and is not given or endorsed by the Barclays Group.
Barclays Bank PLC.Registered in England and Wales (registered no.
1026167).
Registered Office: 1 Churchill Place, London, E14 5HP, United Kingdom.
Barclays Bank PLC is authorised and regulated by the Financial Services
Authority.
--------
website: http://www.LazyDBA.com
Please don't reply to RTFM questions
Oracle documentation is here: http://tahiti.oracle.com
To unsubscribe: see http://www.lazydba.com/unsubscribe.html
To subscribe: see http://www.lazydba.com
By using this list you agree to these
terms:http://www.lazydba.com/legal.html
------------------------------------------------------------------------------
This email is confidential and may be legally privileged.
It is intended solely for the addressee. Access to this email by anyone else, unless expressly approved by the sender or an authorized addressee, is unauthorized.
If you are not the intended recipient, any disclosure, copying, distribution or any action omitted or taken in reliance on it, is prohibited and may be unlawful. If you believe that you have received this email in error, please contact the sender, delete this e-mail and destroy all copies.
==============================================================================
Oracle LazyDBA home page