XYGATE Merged Audit Reference Manual

Table Of Contents
XYGATE Merged Audit
®
Reference Manual
Appendix E: XMA Host Macros
XYPRO Technology Corporation 205 Proprietary and Confidential
E3: CLEANDB
The CLEANDB macro runs the database cleanup program at a regularly scheduled
interval. Unlike the ARCHIVE process, CLEANDB deletes records from the AUDIT
SESSION and AUDIT DETAIL tables but it does not create ARCHIVE Tables. A
sample macro file named CLEANMAC has been placed in your XMA subvolume to
help you use the CLEANDB macro.
===================================================================
== Macro to run Database Clean Macro CLEANDB ==
== This process deletes record from both the Audit Session and ==
== Audit Detail Tables ==
===================================================================
?tacl routine
#frame
[#push
t_begin_dt
t_end_dt
]
xma_datetime_make <days>
#set t_begin_dt [xma_dt_year4]-[xma_dt_month]-[xma_dt_day]
xma_datetime_make <days>
#set t_end_dt [xma_dt_year4]-[xma_dt_month]-[xma_dt_day]
[$<volume>.<subvolume>.cleandb
[t_begin_dt] == date to start
00:00:00 == time to start
[t_end_dt] == date to end
23:59:59 == time to end.
]
#unframed
Where:
T_BEGIN_DT to T_END_DT is your date range. All records that are greater than or equal
to the begin date and less than or equal to the end date will be considered for possible
deletion. The records in the audit session table are not deleted until all corresponding
records in the audit detail table are deleted. You may also change the begin date and
time.
Example: Keep 60 days of information in the XMA database using today’s date
equal to October 5,2004
xma_datetime_make 60
#set t_end_dt [xma_dt_year4]-[xma_dt_month]-[xma_dt_day]
[$secure.xygatema.cleandb
2000-01-01 == date to start
00:00:00 == time to start
2004-08-06 == date to end
23:59:59 == time to end.
]