Purge Old Data |
Top Previous Next |
This function on the Maintenance menu allows purging of transactions and reservations prior to a given date, to decrease database size and speed up reporting functions. If your computer does not have a lot of memory or your database gets very large, you may find that the functions slow down significantly after awhile. This means that the database is too large for your RAM and must be used from disk, which is thousands of times slower.
The Purge dialog consists of a "Prior-to" Date, several options that determine what type of data is purged, and a file name for doing an automatic backup of the data before purging.
The Purge operation can only be done on the Master workstation (if you're networked), and is best done with any others shut down. Afterwards, each workstation will request a full database refresh to get synced back up.
There are 3 pre-purge values maintained for each Customer to show the number of reservations, number of nights stayed, and total payments that were purged. After a purge, these values will be shown on Reservation History and Transaction History -- see below for more information. However you need to make sure that the appropriate fields are Enabled before you do the purge in order for it to save these values. See Maintenance / Data Field Definitions / Customer Fields and look for the 3 "Cust_Prior_..." fields.
When the Purge Old Data menu item is selected, a dialog with the various options is shown. After selecting the options, click the Purge! button to start (another warning will be shown before proceeding, with a last chance to cancel.) Be aware that the purge operation cannot be canceled once started, and cannot be undone except by reloading a backup!
Purge data prior to:
This date designates the age of the data to be purged (and what will remain "live"). It defaults to the beginning of "last year", which could actually be anywhere from one year ago to almost 2 years ago. We recommend keeping at least 1 full year of data if possible for reporting reasons. If this is not possible, you can adjust the date as needed. If you have several years of data then you can also elect to purge farther back, keeping more data "live".
One thing to note about the date is how it's used when purging -- when purging reservation transactions (and/or the reservations themselves), they will only be purged for reservations that ended prior to the given date. Therefore any reservations ending after that date will retain its complete history, even if some of the transactions happened prior to the date. However, customer transactions and unbound transactions will be purged as long as the transaction happened before that date. (Therefore a customer might have some of its transactions purged, but not others that were for a reservation ending more recently.)
Backup prior to purging:
Unless you clear out this field, a backup will be made prior to the purge function. We recommend that you also do a manual backup, just in case this file cannot be written for some reason. By default, it will put the backup in the same folder as your current database, and will use the same name with "backup as of yyyy-mm-dd" appended to it. Once the purge is done, you can reload that file at a later time to access the historical (purged) data. It's important to note that the backup file will be the complete database as of the time you perform the purge, rather than just the purged data.
IMPORTANT: If you do multiple purge operations on the same day (for instance with different options), the default file name will be used each time -- this will overwrite the original backup with the "newer" database, so the original purged data will be lost! Be sure to double-check the file name and change it if necessary to avoid overwriting an existing backup. You will be warned that the file already exists and can cancel the operation, but you need to be aware of why it's important to not overwrite it.
What will be purged
You can purge transactions, reservations, and customers.
Generally you will not want to purge customers, since that's your core customer database. In extreme memory conditions you may elect to purge the ones that have not been used for a long time, but otherwise it's not recommended.
Transactions primarily dictate what can be purged. Unless you select the "Extreme" option (see below), only transactions that "balance" will be purged (meaning there is a $0.00 balance for the reservation or customer in question), and the associated reservation or customer can only be purged if all of its transactions are purged. Therefore any old reservations or customers with outstanding balances will remain forever unless they are manually "cleaned up". The Payments Due tab report can be used for finding unbalanced reservations and customers.
You can choose which transactions are purged -- unbound, customer, or reservation transactions. For instance, you may decide to only purge unbound transactions (generally counter sales) and leave any bound to customers and reservations for historical purposes. Or you can purge customer-only transactions (also usually counter sales), or all reservation transactions.
In addition to the transactions, you can purge the actual reservations that ended prior to the date. Again, this will only be done if the reservation "balances", unless the "Extreme" option is selected. Any transactions for the reservation will be purge automatically, whether you selected the option to purge reservation transactions separately or not.
Finally, customers who don't have any reservations or transactions can also be purged if desired, to help clean out old customers who don't return often. This is done after any other selected purgings above, so if all of its transactions and reservations are purged now, then it will also be purged now. There is also an option to only purge customers that have "never" had any transactions or reservations. If this is selected, it will check the "prior" transaction and reservation figures (explained below), and keep the customer if it has any history -- therefore, even if the customer's transactions and reservations are purged, it will be kept because it had history prior to the purge. This can be useful for cleaning out customers who were entered or imported from an old database but never returned since the software has been in use.
You can also choose to KEEP any customers with warning flags (even if they have no transactions or reservations) -- this is often a good idea, since you will want it to remember that the customer was flagged so you can prevent future reservations for them.
When all of the options are set the way you want, and you're sure you have a backup, you can click the "Purge!" button. The purge should only take a few seconds, and a dialog will show how many records of each type were purged.
"Extreme" purging options
There are options for "Extreme" Transaction or Reservation purging, but these should only be used if you're not concerned with keeping reporting consistent. Typically this would only be the case if you're taking over the park and wanting to start all over with a "clean slate". You can use these to clear all old transactions, reservations and even customers. Note that the normal A/R and Deposit balance adjustments added after purging may not be relevant when using these options, so it will be up to you to look for those and manually remove them or adjust them (perhaps through Raw Data Tables / Transactions).
Extreme Transaction Clean-Up -- With this option selected all transactions prior to the given date will be deleted. This is regardless of any balance, or even if those transactions are part of a current (or past) reservation that also has newer transactions not deleted. Therefore if it's used improperly, it can not only affect past reporting but also current reporting (especially Receipts by Category) and reservation balances. We recommend only using this if you're wanting to wipe out all transactions in the entire system (using a Prior-To date of today's date, for instance).
Extreme Reservation Clean-Up -- With this option selected, all reservations prior to the given date will be deleted. This is regardless of any balance, or even if those reservations are linked to more recent reservations. Therefore if it's used improperly, it can not only affect past reporting but also current reporting (especially Receipts by Category) and customer balances.
Customer Clean-up -- If you're wanting to also clear out old customers for the reservations (or transactions) cleaned up with the Extreme options above, select the "Purge all customer records..." option as usual. Be sure to not select "Purge customers only if they have never..." option.
Keeping prior totals
Although the records are purged, a few "prior" balances are maintained for historical purposes (if the Customer fields are enabled -- see above).
When transactions are purged for reservations or customers, the total amount of payments made in those transactions will be saved (as a single value) and will show up on the Transactions History (done from Customer Details) . This is also added to any total from prior purges. Thus you can still get an idea of how much revenue each customer/reservation has been responsible for.
When reservations are purged, their customers will retain a running total of the number of days-stayed and number of reservations purged. This will show on the Reservation History dialog as a quick reference to show how much business they did in the past that's not still "live".
Keeping balances
Deposit and Accounts Receivable balances (if you use them) are maintained by making "Adjustment" transaction entries automatically. Generally this is only necessary when purging Unbound transactions, which don't have to balance to be purged, since the net balance for purged reservation and customer transactions should be zero. The "Operator" name for these adjustments will indicate that it's an automatic adjustment due to a purge.