About Removing Historical Data | Teradata Vantage - 17.00 - 17.05 - About Removing Historical Data - Advanced SQL Engine - Teradata Database

Teradata Vantage™ - Database Administration

Product
Advanced SQL Engine
Teradata Database
Release Number
17.00
17.05
Published
June 2020
Language
English (United States)
Last Update
2021-01-22
dita:mapPath
rgu1556127906220.ditamap
dita:ditavalPath
lze1555437562152.ditaval
Historical data in TDMaps tables can take up too much space. To clean up old data and regain space, periodically run TruncateHistorySP. For example:
call tdmaps.truncatehistorysp(date '2016-01-01', :numdeletedrows);
*** Procedure has been executed.
*** Warning:  3212: The stored procedure returned one or more result sets.
 
NumDeletedRows
--------------
          35
 
*** ResultSet# 1 : 3 rows returned by "TDMAPS.TRUNCATEHISTORYSP".
 
Table           NumRowsDeleted
--------------  --------------
ActionHistory      10
LogTbl             20
AnalyzeLogTbl       5