[Need Help] Want "Replaced Online Library" but cannot use it due to error

Dear Zotero team,

I have a problem with my sync in the following scenario: after using Zotero sync including file sync for a long time, I went without sync for a few months. My storage subscription had expired and I deleted all online data.

Now that you support pdf annotations and iOS, I would like to use your sync service again. Yesterday I renewed the storage subscription and wanted to sync my library. Unfortunately, I then got an error message that my Zotero database was last synced to another account (which is not true). According to the error message, my local data will be replaced by the remote state, so everything will be deleted.

Actually, I want to use the "Replaced Online Library" feature: The remote state should be replaced by my local dataset. However, I can't get to this function because of the error message.

What can we do?

I am a computer scientist and can manually modify my local SQLite database if needed, in case that helps. But by what value on what database table does the Zotero server want to know that my local database is "wrong"? Or can you somehow reset my online storage so that the sync starts fresh again?

Unfortunately, exporting and importing via RDF is not an option, since too much metadata is lost (e.g. my links to related entries, various attachments, etc.) I tested this yesterday: I confirmed the error message ("Switch accounts"), all my local data was deleted (I have a backup). I then imported an previous RDF export. The synchronization then also starts, but, as I said, too much metadata is missing.
  • Unfortunately, I then got an error message that my Zotero database was last synced to another account (which is not true).
    Yes, it's true if it's saying that. It doesn't just make up two different account names. To sync that database, you need to switch back to the account it tells you in the message.

    If you want us to transfer your storage subscription to the other account, email storage@zotero.org to request that.

    You should absolutely not touch the database, and we won't provide any further help here if you make manual changes to the database.
  • edited July 8, 2021
    Thanks for the quick response. I actually never had another Zotero account. Here is a screenshot of the error message confirming that:

    [link removed]

    I have not manually manipulated my local database yet, though.

    This probably means that my local database has been corrupted. So my thought was that the server probably tries to recognize my database not with the username (alone) but with a unique ID, for example a UUID (https://en.wikipedia.org/wiki/Universally_unique_identifier).

    If there's no other way, I guess I'll have to write a Python script that transfers all the records from my backup to a new, empty database that will be synchronized. The SQL schema seems to be quite simple so far.
  • If you go to Tools → Developer → Run JavaScript and run Zotero.Users.getCurrentUserID(), what's the result?
  • Thanks for pointing this out. In fact, the user id in my local database was set to 1, instead of the real user id that I now know. I corrected the value in my backup, now Zotero synchronizes again respectively I can run "Replaced Online Library" now. Maybe I had manually set the user id in my local database to 1 at that time, when I decided to work without sync. Thanks for the support and sorry for the inconvenience. I look forward to when you invite the next users for the iOS beta, as my request is still in the queue. You send out invites once a week, I seem to have read.
Sign In or Register to comment.