statify
statify copied to clipboard
Feature request: Export and import Statify Data for Relaunch
After a relaunch of a site, I want to see how the traffic is going on. For this I need to export the data in the old version of the site and import this in the new version. Would be great, if you add this as feature in Statify. Actually it looks like you have
- to export the table with phpMyAdmin in the old site,
- if Databasename changed you have to change it in the sql-file
- mostly the prefix of the table changed. You can do this in the sql-file or by phpMyAdmin (https://help.one.com/hc/de/articles/360002107438-Tabellenpr%C3%A4fix-f%C3%BCr-WordPress-%C3%A4ndern#step-2)
- before import in the new site, I delete the statify-table in phpMyAdmin and than import the old data.
- After import you have to restore the settings of statify manually. I think to do this by export this information from options table is too complex I think, there are others who want to see the development of visitors after a relaunch and a simple export/import function would be helpfull thanks Gerd
I'd split this in two or three parts.
First of all the data export. Most straight forward way would be to simply generate a 3-column CSV, TVS, JSON or whatever text-based export file (assuming we don't care about artificial IDs in this dataset). This feature alone might already be useful for additional, external analysis or the (of course rally rare) case that someone might want to migrate to a different tool.
Second part the data import. This part should be at least able to import exactly the exported format, so we can achieve a full roundtrip or the relaunch scenario.
I suggest to add some convenience switches here as well.
- A switch "replace all data", i.e. don't care about the current DB contents, delete everything and import.
- Probably another option "replace data in imported time window". So if we import data from 2022-07-01 to 2022-07-31 and relaunched on August 1st, we delete the "old" data (likely from testing), but keep the new data.
- Import of arbitrary data would be really handy for migration from different tools. Maybe something like detection from first row in a CSV file and manual assignment of the detected columns. Might be postponed to a later stage as well.
Third and last part the config export. There are some configuration migration tools out there that are capable of exporting generic WP Options (Statify does not use anything special here). Sure we might add an "import/export config" feature as well. There are not many use cases for such feature, the config itself is not very complex, so I'd assume we typically talk about new/copied sites here. If not, we should at least think about the impacts, e.g. add some sanity checks and not simply parse arbitrary input against the defaults, which might reset storage period or something and thus delete data.