Home Page for the TeradataForum

Archives of the TeradataForum

Message Posted: Wed, 26 Jun 2002 @ 11:47:18 GMT

  <Prev Next>   <<First <Prev

Subj:   Re: TDQM and Limits of CPU
From:   Dennis Calkins


DBQM/TDQM work by first obtaining the explain for the query. It then looks at the optimizer Estimates for Spool usage, number of rows, CPU times what have you. It then compares those values to LIMITS you have set via the RULES editor. you can have rules based upon time of day or even user.

Dennis is not allowed to execute a query before 6 pm.

Dennis is not allowed to execute a query before 6 pm if it uses more than 5 minutes of CPU.

Dennis is not allowed to execute ma query if it creates more than 3 meg spool.

NO user is allowed to run a query longer than 1 hour.

BOB can always execute a query.

The way it stops a run away query is given the RULE if it is estimated it will be a HUGE query in terms of space or time you can tell the server to ABORT it before it even starts ( save the time it took to parse it and generate the explain ).

However the enforcements of the rules are based upon the optimizers estimates. If the optimizer gets the wrong estimate because of out of date statitics or other factors beyond its control DBQM/TDQM may block queries or allow queries when it shouldn't have. I should point out that we strive to make our optimzier estimates as accurate as possible so if you feel there is an issue here open an incident with the GSC.

Now the main difference between DBQM (pre 4.1) and The new TDQM feature (post 4.1) is where the RULES are validated.

With the pre 4.1 DBQM product, only ODBC queries submited through the DBQM enabled ODBC driver were validated. Also the query was submitted twice. Once to obtain the explain, and again if the RULE allowed the query to execute.

With the new 4.1 TDQM product, all SQL coming into the box can be validated based upon the rules. Also since the RULEs validation is done inside the server, the query is only submitted once and it is aborted or allowed after the parser has generated the plan for executaion along with all of its internal estimation calculations and those values are validated against the rules.

However in either case the query never actually executes if it fails the RULES validation.

  <Prev Next>   <<First <Prev
  Top Home Privacy Feedback  
Copyright for the TeradataForum (TDATA-L), Manta BlueSky    
Copyright 2016 - All Rights Reserved    
Last Modified: 27 Dec 2016