W3C home > Mailing lists > Public > www-rdf-interest@w3.org > September 2003

[CWM] Question about notation, restoring trees out of triples

From: James Michael DuPont <mdupont777@yahoo.com>
Date: Mon, 8 Sep 2003 00:26:41 -0700 (PDT)
Message-ID: <20030908072641.68558.qmail@web41511.mail.yahoo.com>
To: www-rdf-interest@w3.org

Dear Rdf Interested,

Can you please help think about this problem :

I would like to transform a set of triples that form an a-cyclic graph,
a tree even from this notation :

_:foo     <#rel> _:bar .
_:bar     <#rel> _:baz .

Into this notation :

_:foo     <#rel> [ <#id> _:bar;  <#rel> _:baz ].

The problem is that i would also like to copy the attributes :
_:bar     <#attr> "FooBar" . 
as well
to make 
_:foo     <#rel> [ <#id> _:bar;  <#rel> _:baz;  <#attr> "FooBar" ].

The rules I have tried are  :

{
  ?X ?P ?Y.
}
=>
{
?X  ?P
    [
	:id ?Y.
    ] 
}.

But the produces lots on anonymous [id: <#blah>] objects that are not
connected.

Is it possible to restore such a tree structure back in the [ a :tree;
:branch [ a :branch]] notation using cwm?

if so how can this be done? If not, does anyone else need this feature?

thanks

mike



=====
James Michael DuPont
http://introspector.sourceforge.net/

__________________________________
Do you Yahoo!?
Yahoo! SiteBuilder - Free, easy-to-use web site design software
http://sitebuilder.yahoo.com
Received on Monday, 8 September 2003 03:26:42 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Monday, 7 December 2009 10:52:02 GMT