Merged two users, submission disappeared in user profile in OJS 3.1.0.1

I recently had a request to change a username. Since this is not possible, I suggested to create a new profile with the desired username and then merge the old profile into the new one.
As I understood from the OJS documentation, all assignments and submissions of the old profile should then be present in the new profile. Only, they aren’t. There were no current assignments anyway but one published submission in the user’s archive of the old profile. However, after merging, the submission does not appear in the new profile. Also, when I go to the submission page in the dashboard (editor’s view), the participant box on the right is loading infinitely. The published article page on the front end / website looks fine, though.
How can I fix or at least undo this?

We are using OJS 3.1.0.1.

Hi @heike_riegler,

Do you get anything interesting in your PHP error log when you see the endlessly-loading page?

Regards,
Alec Smecher
Public Knowledge Project Team

Hi @asmecher,

the error log says:

PHP Fatal error: Call to a member function getFullName() on a non-object in /var/www/ojs.openagrar.de/lib/pkp/controllers/grid/users/stageParticipant/StageParticipantGridCellProvider.inc.php on line 36

1 Like

Hi @heike_riegler,

Did you get any warning or error during the user merge?

It looks to me like some assets were not successfully merged, so some data still relates to the old account. Upgrading may resolve this for future merges. I’d suggest checking for inconsistent data in the stage_assignments table – especially entries that refer to nonexistent users:

SELECT sa.* FROM stage_assignments sa LEFT JOIN users u ON (sa.user_id = u.user_id) WHERE u.user_id IS NULL;

This should return an empty set, but I suspect in your case it will not.

Regards,
Alec Smecher
Public Knowledge Project Team

1 Like

Hi @asmecher ,

thanks for your help. We have tested an upgrade from 3.1.0.1 to 3.1.2 on our OJS test system, but have problems activating our custom theme (it is uploaded, the plugin is activated, but the drop down menu on ‘appearance’ only contains the default theme That’s a topic for another thread I guess). Until this is solved, we cannot proceed to upgrade the production system.
Anyway, there were no messages during the user merge process. The SQL query you suggested returned actually 5 entries. One of them is the submission that disappeared in the current merge.

What to do now?

All the best,
Heike

Hi @heike_riegler,

I would try to UPDATE the entry in stage_assignments for that submission and old user ID so that user_id points to the ID of the new user account, rather than the old one.

Regards,
Alec Smecher
Public Knowledge Project Team

1 Like