Home Page for the TeradataForum
 

Archives of the TeradataForum

Message Posted: Fri, 20 May 2005 @ 16:47:52 GMT


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


Subj:   How to handle partition maintenance
 
From:   Kevin Bert

Can some folks from the field share how they handle partition (PPI) maintenance? How do you drop and add partitions as needed by your batch cycles?

In Oracle, we have PL/SQL packages that enable/empower the batch user to drop the low partition and add a new high partition. I am trying to figure out a way using stored procedures in Teradata. Dropping the low partition is easy, I can just drop the range where partition = 1. But how do I find the value of the highest partition. Since the partition could be empty, I can't select max(partition) from the table because that won't tell me about the high empty partitions if there are any. I've searched the database dictionary up and down to find a view or table to help with this endeavor by giving me the partitions and the values, but have come up empty handed.

I guess the option is for us DBA's to add partitions manually as needed, but I'd much rather have stored procedures that the batch process can call to automatically add the partitions it needs.

BTW, the version is V2R5.1.


Much thanks.

Kevin



     
  <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