What is the Teradata TD_WhichMax Function? Teradata releases new SQL features with each update, providing enhanced functionality and improved performance with reduced resource usage. We will examine the Teradata TD_WhichMax and TD_WhichMin functions...
This article will show a case study from my past projects. It is an implementation in which, from a row per primary key that contains a start date and an end date, rows are to be generated for all days in between. I have simplified the query for demo...
Occasionally, it is necessary to utilize a cursor within a stored procedure to execute specific functionality. I recently encountered a stored procedure that contained a loop with multiple INSERT statements executed through a cursor. This particular...
Discover how Teradata summary statistics provide valuable information about the number of rows in a table, helping to optimize performance tuning.
Teradata ORDER BY and Performance If we chose a simple sort method, all rows would have to be available in one place to be sorted. This is, of course, not possible in Teradata, as hundreds of AMPs hold a portion of each table. Copying all rows to one...
In a previous article, Roland explained how to use recursion to build a data range without touching a physical table. This time, we explore an alternative approach that avoids recursion at the expense of single-AMP, single-row access. We can use this...
Learn about the differences between GROUP BY and DISTINCT for aggregations in Teradata. The optimizer now selects the appropriate algorithm depending on data demographics. Understand when to use each method to optimize query performance.
A Teradata Transient Journal is a dictionary table maintained across the whole system to protect transactions against system failures and deadlocks. Each AMP manages its local Transient Journal, where the table rows are copied before being changed by...
Teradata uses different join methods and has different ways to bring the rows of the two tables to a common AMP, which is a prerequisite for joining. Join geography and join method are called join strategy; for both, the goal is to minimize the resou...
What influences the Teradata Load Performance? Teradata allows only a limited number of bulk loads to be executed together as they consume many resources. The precise limit depends on your Teradata system. It will be somewhere in the lower 2-digit ar...