• Login
  • Register
  • Login Register
    Login
    Username/Email:
    Password:
    Or login with a social network below
  • Forum
  • Website
  • GitHub
  • Status
  • Translation
  • Features
  • Team
  • Rules
  • Help
  • Feeds
User Links
  • Login
  • Register
  • Login Register
    Login
    Username/Email:
    Password:
    Or login with a social network below

    Useful Links Forum Website GitHub Status Translation Features Team Rules Help Feeds
    Jellyfin Forum Support Troubleshooting Deleting empty music genres

     
    • 0 Vote(s) - 0 Average

    Deleting empty music genres

    How can empty music genres be removed from the UI?
    PaulMc
    Offline

    Junior Member

    Posts: 12
    Threads: 6
    Joined: 2023 Oct
    Reputation: 1
    Country:United Kingdom
    #1
    2026-02-16, 03:58 PM
    I've a large music collection on a NAS and have recently had time to clean up the metadata on the audio files. This has resulted in a few genres becoming empty (mainly because of typos). However, I cannot find a way of removing them permanently. I've used the trick of renaming them, which then works for a short while but then the next morning they are all back. I've manually rescanned the library folder replacing all metadata (but not images), and this makes no difference - they return the next day. I presume the reappearance is because of a setting in the overnight scheduled processes? I've double checked the metadata using other software and cannot see these phantom genres anywhere however they keep returning and are empty when selected in the Jellyfin UI. Please can anyone suggest a process by which I can remove these genres permanently?
    mellowmint
    Offline

    Junior Member

    Posts: 3
    Threads: 0
    Joined: 2025 Apr
    Reputation: 0
    Country:United States
    #2
    2026-03-14, 04:05 AM (This post was last modified: 2026-03-14, 04:23 AM by mellowmint. Edited 1 time in total.)
    I had a situation where I inadvertently dropped 1 album of song files into an artist's folder directly, like I didn't make an album folder.
    Well, no album folder means no album displayed in Jellyfin, which means those songs weren't shown under the artist either.

    The only place these songs had presence in Jellyfin was under the "Songs" section, a single file list which basically made them invisible.
    ~250 artists, ~1000 albums, ~11,000 songs, and 9 of those songs aren't represented on any artist or album page, just somewhere in a 11,000 item list
    Easy to notice, right?

    A genre "alternativa e indie" was only on this one album, so I scrubbed that. But the genre keeps coming back. Except no other albums had that genre. Especially after scrubbing the one instance, it really felt like I fixed the source of the genre occurring but Jellyfin wasn't updating or Jellyfin was holding onto old data or something. I was wrong.

    If you are deleting it and it's recreating it... I bet you still have the tag somewhere.



    1. Stop Jellyfin so you can touch the database

    systemctl stop jellyfin

    2. Use sqlite3 to open the database

    sqlite3 /var/lib/jellyfin/data/jellyfin.db

    3. Genres are stored in "ItemValues" and this command will print all existing genres

    SELECT DISTINCT Value FROM ItemValues WHERE Type = 2;

    4. This command returns genres, if no database item is attached. But it should return empty.

    SELECT DISTINCT iv.Value
    FROM ItemValues iv
    LEFT JOIN ItemValuesMap ivm ON iv.ItemValueId = ivm.ItemValueId
    WHERE iv.Type = 2 AND ivm.ItemValueId IS NULL;

    5. Replace the word Genre in the command below with any existing genre you believe should be empty / should no longer exist.
    You can reference the table from step 3 if needed. This command returns all items with the named genre.

    SELECT bi.Name, iv.Value

    FROM BaseItems bi
    JOIN ItemValuesMap ivm ON bi.Id = ivm.ItemId
    JOIN ItemValues iv ON ivm.ItemValueId = iv.ItemValueId
    WHERE iv.Type = 2 AND iv.Value = 'Genre';


    It is a good tool to find which music files you may need to change.
    I would refrain from editing the DB and only use it for investigation.
    Make changes to your music files and let the DB update itself.

    To exit sqlite3 again, use .quit
    And don't forget to systemctl start jellyfin
    « Next Oldest | Next Newest »

    Users browsing this thread: 1 Guest(s)


    • View a Printable Version
    • Subscribe to this thread
    Forum Jump:

    Home · Team · Help · Contact
    © Designed by D&D - Powered by MyBB
    L


    Jellyfin

    The Free Software Media System

    Linear Mode
    Threaded Mode