HOW TO FIND THE FIRST 20 WORST RUNNING QUERIES LISTS IN TERADATA

General
Enthusiast

HOW TO FIND THE FIRST 20 WORST RUNNING QUERIES LISTS IN TERADATA

Hi Everyone,

Could anyone please help me how to find the worst running queries lists in teradata?

Hope i will get the response soon....

Regards,

Purushotham.

2 REPLIES
Enthusiast

Re: HOW TO FIND THE FIRST 20 WORST RUNNING QUERIES LISTS IN TERADATA

Viewpoint.....or running query : from table(syslib.MonitorSession(-1,'*',0)) AS TA

Enthusiast

Re: HOW TO FIND THE FIRST 20 WORST RUNNING QUERIES LISTS IN TERADATA

or of course you could search these forums for articles like the following...http://developer.teradata.com/viewpoint/articles/killer-queries-track-them-find-them-fix-them

Some other calculations of interest include:

Product Join Indicator , results > 6 could be a performance issue, (TotalCPUTime *1000)/TotalIOCount = PJI.  this may be distorted by large aggregations, numerous substring, case or index (not table index, but index("string","instring",startnum))functions.

Unnecesasry IO Indicator, TotalIOCount(TotalCPUTime*1000) , yes the inverse of the PJI function.  results > 6 could indicate a missing index

ImpactCPU, MaxAmpCPUTime * (hashamp()+1) , the higher the result, the more impact the query has on the system. A primary metric for reviewing the ugly queries on a regular basis to see signs of improvement