Today when I opened up the app (on my laptop under Linux, but also on my Android phone and on my tablet) I saw a note telling me that my collection was empty!
Yesterday I did a repetition session and synced it back to your servers and now I see nothing there.
I managed to export my data from a phone, first disabling Internet connectivity, but about 30 notes is gone.
Why has this happened to me? I can see the Tags are there (only on PC and phone, not on a tablet), but nothing else.
As for why it happened, the most likely reasons for a completely empty collection are -
Opening the wrong profile – a new, blank profile instead of your regular one. This can happen on a single device if your collection is stored in a location that becomes inaccessible. Anki would then create a completely new profile in a stable location. But there’s no way that would sync to other devices unless you set up syncing and did that.
Doing a one-way sync in the wrong direction.
Your database failed completely – exceedingly rare, but not impossible, I suppose. Again, this couldn’t spread to other devices without you syncing.
I wish you could give us more specifics about what the message said. Having the exact error message is the easiest way to track things like this.
I don’t think there’s any way of knowing exactly what happened without knowing what the notification you got was. But I’m glad you were able to restore everything. Make sure you are fully synced on all devices.
Got it. Since you were able to recover from your local backup, and your data wasn’t actually gone – it seems likely that either you were looking at a different profile that Anki created for you, or you had a one-way sync that went the wrong way.
Have you looked to see if there is another unexpected profile in your system? You can check File > Switch Profile and/or look in your Anki2 data folder (each profile is its own folder). If you find one, it’s probably best to delete that.
The next thing to check – especially if you’re not using the default storage location – would be to search your system to make sure there isn’t another Anki2 folder that Anki was trying to use.
Other than that – run Check Database, to make sure your collection is healthy, and make sure your devices are all properly synced, so you’ll have multiple places you can recover from.
Probably it was “a one-way sync that went the wrong way”, since I did not have any other profile at that time.
Recently I have created a second, empty profile. When I try to switch to that empty profile (all devices synced to DB) from my Android devices, I can not find a way to do it. Is that option to switch hidden somewhere, or it is how it’s supposed to be? Maybe I can only switch to a non-empty profile? Or am I simply blind :D?
You can’t sync multiple profiles through a single AnkiWeb account. (Which is one of the reasons that multiple profiles aren’t generally recommended for a single user – https://docs.ankiweb.net/profiles.html.)
AnkiDroid doesn’t have built-in support for multiple profiles. (There’s a workaround, but it’s rarely needed.)
If you created that 2nd profile on your computer, then that’s the only place it exists.
In desktop Anki? You can choose Export there, or from File > Export in the main screen, or from Notes > Export Notes in the Browse window. They all take you to the same place, and the only way that is limited to the entire collection is the COLPKG export. If you choose anything else, you can select how much of your collection to export. Exporting - Anki Manual