Home Page for the TeradataForum
 

Archives of the TeradataForum

Message Posted: Sat, 13 Dec 2008 @ 17:50:32 GMT


     
  <Prev Next>   <<First <Prev Next> Last>>  


Subj:   Re: Help on cursors in teradata
 
From:   Rob Paller

Sridhar,

The use of cursors will result in serialized processing, a strength on Oracle but a weakness on Teradata. You may want to consider maximizing the parallel efficiency by leverage SET based processing with macros, volatile tables, and OLAP functions in your ANSI-SQL.

Macros will allow you to bundle multiple SET based statements together as well as obscure the access rights necessary to manipulate the objects involved. The user only needs the ability to execute the macro explicitly and the actions contained within the macro will be implicitly permitted.

Volatile tables will allow your process to work within a users spool space and provide temporary working storage for your processes. Global temporary tables work within a users temporary space. Until recent releases of Teradata, volatile tables did not permit you to collect statistics on them while global temporary tables did. When working with thousands (tens and sometimes hundreds of thousands) the lack of statistics aren't necessarily detrimental to the execution plans.

Some of the strengths that OLAP functions on Teradata provide you the ability to peek forward and behind within a given partition. This would afford you some flexibility in your ETL processing. This is above and beyond their strengths in analytical applications as well.

Cursors have their place in Teradata but should be considered carefully as they can slow down your overall process substantially.

Hope this information is useful. If you are able to provide more detailed questions about what you are trying to accomplish it would be possible for everyone to offer more useful suggestions.


Regards,

Rob



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