Skew Factor & Stats

Database

Skew Factor & Stats

Hi,

I am quite new here to Teradata...Can anyone help me onthe query.. I am looking out for skew factors for certain tables.I would like to know the query for the same and what would be the desired value or range which is acceptable.

Also i would like to know the query to see for what all columns of a table the stats is already collected and what is not collected. Appreciate your help ASAP.

tHANKS 

sUNNY

5 REPLIES

Re: Skew Factor & Stats

Hi,

You can have a look at this link(look till the end):

 http://www.info.teradata.com/HTMLPubs/DB_TTU_14_00/index.html#page/Database_Management/B035_1094_111...

One way is you  can have a look at dbc.statsv and verify too in  the qrylog table or dbql

Re: Skew Factor & Stats

tHANKS.

One quick question..do we need to refresh a view once we collect stats for its underlying table?

Re: Skew Factor & Stats

You dont need to refresh. I think you come from Oracle background, where you see materialized view, where  you can refresh.

Re: Skew Factor & Stats

Hia thanks Raja..One more question..I am querying on a database to find the skeness of all tables..The result shows me including that of the stored procedures too and all stored procedures shows skeness of greate than 90..Is there something wrong?

Teradata Employee

Re: Skew Factor & Stats

Skew should not be considered important for any object smaller than a few data blocks per AMP. There is just not enough statistical distribution to get an even distribution. And skew for very small objects will not cause a noticeable performance issue. SPs are very small and each is purposely stored on a single AMP so they will always be skewed.