Remove Historical Data | Teradata Vantage - Removing Historical Data - Analytics Database - Teradata Vantage

Database Administration

Deployment
VantageCloud
VantageCore
Edition
Enterprise
IntelliFlex
VMware
Product
Analytics Database
Teradata Vantage
Release Number
17.20
Published
June 2022
Language
English (United States)
Last Update
2023-11-03
dita:mapPath
pgf1628096104492.ditamap
dita:ditavalPath
qkf1628213546010.ditaval
dita:id
ujp1472240543947
lifecycle
latest
Product Category
Teradata Vantageā„¢

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);

Result:

*** 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