1

My title says it all. Unfortunately, this post is causing havoc, as my app is built around the idea that the MediaStore IDs do not change, but apparently they all do.

How are developers supposed to store MediaStore information about Songs/Artists/Albums/Genres/Playlists if they do not have stable ID's of some kind?

Saving by name seems like a bad idea. The user can easily change the name of any of the above and throw a monkeywrench in your app.

Community
  • 1
  • 1
Andrew No
  • 535
  • 6
  • 20
  • The most common way to query the database is by using the mp3 tags, not by id. How in gods name would you know/remember a track id? – Theo Apr 21 '16 at 06:16
  • @Theo, you can use Cursor.getLong(currentCursor.getColumnIndex(MediaStore.Audio.Media._ID) to get the ID and store it like other variables. – Andrew No Apr 22 '16 at 02:31

0 Answers0