 |
 |
Archives of the TeradataForum
Message Posted: Fri, 29 Oct 2010 @ 14:04:15 GMT
Subj: | | Re: Uneven distribution of data |
|
From: | | Anomy Anom |
<-- Anonymously Posted: Friday, October 29, 2010 10:01 -->
The DBC.tablesize view will show uneven data distribution for tables on your system. You may find this query useful.
sel databasename, tablename
, sum(currentperm) sum_perm
, max(currentperm) as high_amp
, max(currentperm)/sum(currentperm) *100 as PctOnHighAmp
, (max(currentperm)*(max(vproc) +1))/ sum(currentperm) as skew_factor
, ((max(currentperm)*(max(vproc) +1))/ sum(currentperm) /(max(vproc)+1)
)*100 as skew_percentage
, min(currentperm) as low_amp
, avg(currentperm) as avg_amp
, stddev_pop(currentperm) as stddev
from dbc.tablesize
group by 1,2
having sum(currentperm) > 10000000
order by skew_factor desc
| |