[gnome-music/wip/jfelder/musicbrainz-tageditordialog: 50/54] query: Get additional tags from the Songs query



commit 1ff6148f47c1f72fc79edc670193eeee9938bd31
Author: Jean Felder <jfelder src gnome org>
Date:   Mon Aug 20 00:08:50 2018 +0200

    query: Get additional tags from the Songs query
    
    Retrieve composer, track_number, album_disc_number, genre and
    creation_date.

 gnomemusic/query.py | 5 +++++
 1 file changed, 5 insertions(+)
---
diff --git a/gnomemusic/query.py b/gnomemusic/query.py
index ac7707f8..d6c9de6c 100644
--- a/gnomemusic/query.py
+++ b/gnomemusic/query.py
@@ -194,10 +194,15 @@ class Query():
         ?url
         nie:title(?song) AS ?title
         nmm:artistName(nmm:performer(?song)) AS ?artist
+        nmm:artistName(nmm:composer(?song)) AS ?composer
+        nmm:trackNumber(?song) AS ?track_number
+        nmm:setNumber(nmm:musicAlbumDisc(?song)) AS ?album_disc_number
         nie:title(nmm:musicAlbum(?song)) AS ?album
         nfo:duration(?song) AS ?duration
+        nfo:genre(?song) AS ?genre
         ?tag AS ?favourite
         nie:usageCounter(?song) AS ?play_count
+        YEAR(nie:contentCreated(?song)) AS ?creation_date
     {
         %(where_clause)s
         ?song a nmm:MusicPiece ;


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]