Purge procedures and parameters

From Genesys Documentation
Revision as of 02:39, July 25, 2020 by WikiSysop (talk | contribs) (Text replacement - "\|Platform=([^\|]*)GenesysEngage-onpremises([\|]*)" to "|Platform=$1GenesysEngage-cloud$2")
Jump to: navigation, search
This topic is part of the manual Workforce Management ETL Database Reference for version Current of Workforce Management.

Learn how to safely and efficiently purge data in the WFM ETL database.

Related documentation:

The WFM ETL database script includes the following database-stored procedures used to enable purging of the ETL database:

Procedure
Description
WFM_PURGE_PROC
The main procedure, used to call all the procedures below, passing a date that is calculated by subtracting a specified number of days from the current date.


This procedure is designed to be executed regularly (daily or more often) as a scheduled task.

Use the following parameters with this procedure:

  • @DAYS_BACK_FOR_DAY—Purges daily granularity data that is older than the specified number of days from the current day. For example, if this parameter value is10, WFM purges data that is older than 10 days prior to today (data for the 10 days prior to today, plus today's data is retained).
  • @DAYS_BACK_FOR_TIMESTEP—Purges 15-minute granularity data that is older than the specified number of days from the current day. See the example above.
  • @MAX_PURGE_CHUNK—Specifies the maximum number of records to purge in one pass.
WFM_PERF_PURGE_PROC
Purges performance statistics data older than a given date.


Use the following parameters with this procedure:

  • @PURGE_DATE—Specifies the purge date. Data older than this date is purged.
  • @MAX_PURGE_CHUNK—Specifies the maximum number of records to purge in one pass.
WFM_SCH_PURGE_PROC
Purges schedule data older than a given date.


Use the following parameters with this procedure:

  • @PURGE_DATE—Specifies the purge date. Data older than this date is purged.
  • @MAX_PURGE_CHUNK—Specifies the maximum number of records to purge in one pass.
WFM_ADH_PURGE_PROC
Purges adherence data older than a given date.


Use the following parameters with this procedure:

  • @PURGE_DATE—Specifies the purge date. Data older than this date is purged.
  • @MAX_PURGE_CHUNK—Specifies the maximum number of records to purge in one pass.
WFM_CFG_PURGE_PROC
Purges configuration data (uses no parameters).

Specifying the number of records to delete

When using the @MAX_PURGE_CHUNK parameter in the procedures described in the table above, be sure to carefully weight it to prevent overtaxing the database server if there are already millions of records that need purging.

Genesys recommends that you limit the number of records to be deleted in one pass to avoid large transactions and allow the database to purge gradually, during subsequent executions of scheduled purging tasks.

Frequently asked questions

Tip
The information presented here is provided to help you understand how the WFM ETL database purges data. However, if issues arise that require troubleshooting, ask your Genesys Professional Services representative for assistance.

The information in these FAQs might be useful when you are purging the database:

Q: Can you suppress or deactivate the data production for the TIMESTEP tables?
A: No, only the complete subsystem (Perf, Sch, Adh) can be disabled.

Q: When the DaysBack option is set to a value of 30, can you purge the TIMESTEP tables to a retention time lower than 30 days—using an extreme example, TRUNCATE TABLE every night? In this case, would ETL try to recreate the last 30 days of data?
A: Yes, you can purge TIMESTEP tables to a retention time lower than the one specified for DAY tables. No, ETL would not try to recreate those tables unless there was a change in the main WFM database for those days and data was synchronized back to ETL. When data is synchronized for some date(s), both TIMESTEP and DAY tables are synchronized simultaneously.

Q: Is Genesys planning to develop a feature, now or in future versions, that would improve the handling of the huge TIMESTEP tables or provide a way to deactivate them?
A: Currently, nothing is planned, but we might consider a feature of disabling TIMESTEP tables. Please submit a feature request.

Q: What is the best way to start purging the TIMESTEP tables?
A: Depending on the scenario, you might want to schedule a task that would call a main purging procedure at regular intervals. For example, using these parameters: WFM_PURGE_PROC (730, 0, 100000)—where the values in brackets represent the @DAYS_BACK_FOR_DAY, @DAYS_BACK_FOR_TIMESTEP, and @MAX_PURGE_CHUNK tables, consecutively.

Retrieved from "https://all.docs.genesys.com/PEC-WFM/Current/ETLRef/AutoPurg (2024-04-24 21:04:49)"
Comments or questions about this documentation? Contact us for support!