Permalink
Browse files

CSmartPlaylist: improve genre rule for artists

  • Loading branch information...
1 parent be31b8e commit 86a8f57d894fca09e0e6059d92d026277112c092 @Montellese committed Aug 10, 2012
Showing with 7 additions and 0 deletions.
  1. +7 −0 xbmc/playlists/SmartPlayList.cpp
@@ -810,6 +810,13 @@ CStdString CSmartPlaylistRule::GetWhereClause(const CDatabase &db, const CStdStr
else if (m_field == FieldAlbumArtist)
query = GetField(FieldId, strType) + negate + " IN (SELECT album_artist.idAlbum FROM album_artist, artist WHERE album_artist.idArtist = artist.idArtist AND artist.strArtist" + parameter + ")";
}
+ else if (strType == "artists")
+ {
+ table = "artistview";
+
+ if (m_field == FieldGenre)
+ query = GetField(FieldId, strType) + negate + " IN (SELECT song_artist.idArtist FROM song_artist, song_genre, genre WHERE song_artist.idSong = song_genre.idSong AND song_genre.idGenre = genre.idGenre AND genre.strGenre" + parameter + ")";
+ }
else if (strType == "movies")
{
table = "movieview";

0 comments on commit 86a8f57

Please sign in to comment.