DOCUMENTATION

Documentation

Data Cleaning and Maintenance

Data Cleaning and Maintenance

The Data Cleaning page is registered under the Dashboard and rendered by includes/data-cleaning.php. It helps administrators monitor database size and remove old or unwanted tracking data.

Tables shown

  • Clicks: wpmc_bh_clicks, individual click and heatmap events.
  • Views: wpmc_views, page views, sessions linkage, duration, scroll depth, and sources.
  • Sessions: wpmc_sessions, session-level metadata and timing.

Available maintenance actions

  • Clear Clicks: truncates the BH clicks table.
  • Clear Views: truncates the views table.
  • Clear Sessions: truncates the sessions table.
  • Delete All Data: truncates clicks, views, and sessions.
  • Delete Older Data: deletes BH clicks by ts, views by timestamp, and sessions by created_at.
  • Optimize Tables: runs OPTIMIZE TABLE for existing WPMC tables.
  • Per-page cleanup: wpmc_clean_page can delete URL-matching rows from selected table groups.

Table size note: the displayed size comes from INFORMATION_SCHEMA.TABLES. MySQL/InnoDB may keep disk space reserved after deletion, so the reported size may not shrink immediately.