Previous Entry Share Next Entry
(no subject)
These days I'm putting my skills to semi-good use.. It's very geeky, but I've built myself the typical "Music Database".

Now, as far as database projects go, a music database is kind of akin to Hello World, but this one is slightly different. It uses a logical data model that has entities for artists, related to songs, which are related to ratings. And it's auto-populated from my MP3 player. So rather than typing in artists, albums and singles, I just pull the data from the hardware itself. Artists are normalised rather than relying on two text tags being identical. It took a bit of time to fix the data so it was possible, but it's sorted now.

So what I'm left with is a table containing song names (pulled from the ID3 tags by my database), a reference to the artist, the exact location of the file on my MP3 player, and a unique ID for that song. This unique ID is then used in various playlist tables and ratings tables. I can create arbitrary measures on which to rate songs, and store them in an almost infinite number in this ratings table. Right now there's a song score, a score for how calming it is, one for the quality of the guitar, one for how nostalgic it makes me feel, and one for how happy and uplifting it is. I can add more if I so choose.

Of course, then I can build playlists based on ratings. It's a fairly simple SQL query to then build a playlist of songs where the song rating is at least 4/5, and either the Happy or Nostalgia rating is 4+. Before I forget, it's worth noting that playlists can be exported to my MP3 player, so once I'm done compiling one I can just click a button, and it's ready to play on my way to work.

Anyway, I can get myself an average score for ratings on a per-artist basis.. so if I want to add everything by any artist with an average Guitar score of 3+, then it can do that. And every time I add something to a playlist, it remembers what it was and when, so I can also select songs based on how many times I've listened to them.

It really is very neat.. In fact, I'd go so far as to say that it's possibly the best playlist software I've ever used. I mean, obviously that's because I've deliberately coded it exactly as I would want the software to work, but still.. It's nice to be able to add lots of metadata to my music collection, select playlists based on that, and have them automatically run on my mp3 player.. :o)

So yes, I might be a database geek, but occasionally it comes in useful for things that are almost normal.

  • 1
music - it is a part of soul, in language of music it is necessary to speak and it is necessary to understand it. You understand it?

  • 1

Log in

No account? Create an account