[Tracker] About getting ImageList from tracker



Hi, dear developers

I want to store/get nmm:ImageList in/from tracker, and I have succeeded in storing, but I still didn’t find a way to get the list, hope the mail list could help me speed up finding the method. J

 

Below are what I have achieved.

 

Insert:

tracker-sparql -u -q " INSERT { <urn:uuid:image-albumA> a nmm:ImageList ; nie:identifier 'AlbumA' ; nie:keyword 'AlbumATitle' ; nfo:entryCounter 2 ; nfo:hasMediaFileListEntry [ a nfo:MediaFileListEntry; nfo:entryContent <urn:uuid:5ea315ca-54c1-dbdf-45f5-0865a41425fa>] ; nfo:hasMediaFileListEntry [a nfo:MediaFileListEntry; nfo:entryContent <urn:uuid:a35e2d11-5451-c912-bd2f-3e8303dfd4ef>]}"

 

Query:

tracker-sparql -q "SELECT ?imagelist nie:identifier(?imagelist) nie:keyword(?imagelist) nfo:entryCounter(?imagelist) WHERE {?imagelist a nmm:ImageList}"

 

Delete:

tracker-sparql -u -q " DELETE { ?photoalbum a nmm:ImageList } WHERE { ?photoalbum nie:identifier 'AlbumA'}"

 

*here comes the question*, I want to get the whole list of urls from nmm:ImageList, I tried the following, but can’t work

tracker-sparql -q "SELECT ?entry  WHERE { <urn:uuid:image-albumA> nfo:hasMediaFileListEntry ?entry . ?entry nfo:listPosition 1}"  *failed*

tracker-sparql -q "SELECT ?entry ?image ?position WHERE { <urn:uuid:image-albumA> nfo:hasMediaFileListEntry ?entry . ?entry nfo:entryContent ?image; nfo:listPosition ?position}"  *failed*

 

tracker-sparql -q "SELECT ?entry  WHERE { <urn:uuid:image-albumA> nfo:hasMediaFileListEntry ?entry . }" could get something, but I found the result returned are not what I INSERTed.

 

Really appreciated your help!



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