Migrate statistics from 2.4.2.0 to 2.4.8.5 to 3.2.0.3

I had to upgrade a 2.4.2.0 installation to 3.2.0.3, and as an intermediate troubleshooting step I upgraded to 2.4.8.5. I’m doing all this in a “sandbox” install while the original OJS is still live in the old version. I’m having a problem with statistics that I can’t find an easy answer to.

I’ve been reading a lot of forum threads, as well as these documents:
https://docs.pkp.sfu.ca/admin-guide/en/statistics
PKP Statistics Framework - PKP Wiki (in archive.org since the original doesn’t exist anymore)

In my old 2.4.2.0 there was an “Abstract Views” figure in the submission page, i.e. “editor/submission/331”. This figure turned to zero when I upgraded to 2.4.8.5.

And now the 3.2.0.3 seems to have started collecting stats, but starting from zero.

Since I have all previous installs (2.4.2.0, live; 2.4.8.5, intermediate), how can I migrate the old stats to version 3, so users are still seeing the numbers they were used to seeing?

Best regards,
Jorge

Hi @Jorge,

The statistics framework is based on log file parsing, so if you have long-term web server access logs, you can submit them for parsing even though they represent actions that happened before the current version of OJS was installed.

Regards,
Alec Smecher
Public Knowledge Project Team

Thanks @asmecher. Unfortunately I don’t have access to years of back server logs, I could retrieve some from backups but not much.

Is there anything else that can be done, maybe writing some values to the database directly?

Best regards,
Jorge

Hi @Jorge,

Metrics are kept in the metrics table. They aren’t kept in aggregate form (e.g. a total count), so you would need to generate comprehensive data, I’m afraid.

Regards,
Alec Smecher
Public Knowledge Project Team