[Tracker] Tracker-sparql queries
- From: John stacy <tracker indexer gmail com>
- To: tracker-list gnome org
- Subject: [Tracker] Tracker-sparql queries
- Date: Mon, 28 Nov 2011 16:31:54 +0530
Hello Team,
I am trying to construct few sparql queries for artist, album, genre information. I am able to fetch the information successfully. with the below queries
UUID <--> FILE PATH <--> ARTIST NAME <--> ALBUM NAME <-->GENRE <--> BITRATE
tracker-sparql -q "SELECT ?x (SELECT nie:url(?url) {?x nie:isStoredAs ?url })
(SELECT nmm:artistName(?artist) { ?x nmm:performer ?artist } )
(SELECT nmm:albumTitle(?album) { ?x nmm:musicAlbum ?album } )
(SELECT ?genre { ?x nfo:genre ?genre } )
(SELECT ?title { ?x nie:title ?title } ) WHERE { ?x a nmm:MusicPiece }"
Now my question is I want to Fetch all albums or artists or Genre belongs to the files present in a particular folder or mountpath.
How to do this?
I am fetching the file names belongs to a particular folder with the below query.
tracker-sparql -q "SELECT ?uri nfo:fileName(?uri) WHERE {?uri a nmm:MusicPiece . ?uri nie:url ?url FILTER(fn:starts-with(?url, '
file:///home/JOHN)) }"
but unable to fetch the albums/artists/genre information for the files which are present on a particular folder or mountpath.
Can some one help me in framing the query?
Thanks,
Prafulla
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]