Sergey Chernyshev wrote:
> In my techpresentations.org <http://techpresentations.org> wiki, I have 
> conference page like "OSCON 2006" that have [[Series::OSCON]] relations 
> to the conference series pages.
> 
> Is there any way for me to select all objects of "Series" relation, e.g. 
> "OSCON" without selecting subjects of those relations. I also need to 
> have them unique (similar to DISTINCT in SQL).
> 
> This can be easily done using regular RDF tools like Redland for example.
> 
> I can't find solution myself - any help will be appreciated!

Subqueries provide a restricted list of objects to an inline query, e.g.
        [[Series::*]][[Series::+]]<q>[[Blog:=+]]</q>
will only show the pages with a Series relation whose object has a Blog.

BUT, I can't figure out how to get inline queries to just show the 
objects returned by the subquery.

You can fake it by using templates in SMW 0.7 to hide the subjects.  I 
made http://www.techpresentations.org/Test
But you don't get uniqueness; you're still asking for "All pages that 
are the subject of a Series relation, and for each of these the object 
of its Series relation".

However, Yaron Koren recently wrote in "Re: [SMW-devel] Reflexive results?":
 > Well, my mistake - I tried it out, and it appears "inverse queries",
 > i.e. queries that return the object of triples, given the subject,
 > work. And it looks like the functionality has been in SMW for a
 > while... for some reason, it's not mentioned in the help page
 > (http://ontoworld.org/wiki/Help:Inline_queries), and I couldn't see
 > documentation anywhere else either. Is this a secret or unsupported
 > feature? In any case, good to know.

But he didn't say how he got it to work!


Wei Dai posted a patch back on 2006-12-19, "[SMW-devel] patch: inline 
query for inverse relations and relation wildcard", I don't think anyone 
tried it.

--
=S Page

-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
Semediawiki-user mailing list
Semediawiki-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/semediawiki-user

Reply via email to