[Nepomuk] Queries not working as expected

Alessandro Diaferia alediaferia at gmail.com
Mon Jun 7 14:42:36 CEST 2010


2010/6/7 Sebastian Trüg <trueg at kde.org>

> This is totally normal since we have no proper inference support yet. So
> please please just do as I say and use the query api. ;)
>
> This is what you do:
>
> Query::Query query(
>    Query::ResourceTypeTerm( Vocabulary::NFO::Image() ) );
>
> and then query.toSparqlString()
>
> or simply use the QueryServiceClient. Or even simpler in case you are
> using KIO: query.toQueryUrl() and list that via KDirModel or a KDirLister.
>
> Cheers,
> Sebastian
>
> On 06/07/2010 12:40 PM, Alessandro Diaferia wrote:
> > Hello list,
> > as already discussed with Vishesh some minutes ago there seems to be a
> > problem with the following SPARQL query:
> >
> > "select ?url where { ?resource nie:url ?url . ?resource a nfo:Image . }"
> >
> > This query returns less results than it should, skipping for example png
> > files.
> > In particular, as noticed by Vishesh, replacing nfo:Image with
> > nfo:RasterImage or nexif:Photo works fine.
> > Shouldn't nfo:Image cover all types of pictures?
> >
> > My particular code is here: http://pastebin.com/TVj6HJGx
> >
> > Also, is there a way to perform the same query using the API rather than
> > plain SPARQL?
> >
> > Regards
> >
> > --
> > Alessandro Diaferia
> > KDE Developer
> > KDE e.V. member
> >
> >
> >
> > _______________________________________________
> > Nepomuk mailing list
> > Nepomuk at kde.org
> > https://mail.kde.org/mailman/listinfo/nepomuk
> _______________________________________________
> Nepomuk mailing list
> Nepomuk at kde.org
> https://mail.kde.org/mailman/listinfo/nepomuk
>

Thank you Sebastian, it worked just fine.

Missing your live support at Nepomuk-sprint 2009 :)

Cheers
-- 
Alessandro Diaferia
KDE Developer
KDE e.V. member
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.kde.org/pipermail/nepomuk/attachments/20100607/e1701be5/attachment-0001.htm 


More information about the Nepomuk mailing list