Wednesday, September 08, 2004

Trans and Walk in the DAWG

"In order to traverse class/property hierarchies defined in a schema, RQL provides functions such as subClassOf (for transitive subclasses) and subClassOf^ (for direct subclasses). For example, we can issue the queries: subClassOf(Artist) and subClassOf^(Artist) to find all transitive (direct) subclasses of class Artist. Similarly, functions superClassOf and superClassOf^ return transitive (direct) superclasses.

Similar functions exist for schema properties (i.e., subPropertyOf and subPropertyOf^). For example, we can ask for all transitive (direct) subproperties of creates: subPropertyOf(creates) and subPropertyOf^(creates)."

"That's what I had in mind for 4.6 as originally proposed."

I hope I'm correct in characterizing this as the functionality we currently provide in iTQL with trans and walk. Swapping the first parameter's values around swaps between super and sub class. I'd also like to add a limiting factor for recursing called depth.

2 comments:

Anonymous said...

I'm working on a use case motivating these bits as a reading of 4.6 from the UC&R document. I want to make clear, though, that I wasn't proposing that syntax especially; I'm not sure whether this should be syntactic sugar or special predicates or what -- but RQL offers a nice range of functionality that I'd like to have a subset of in the DAWG query language.

Good to hear iTQL has similar stuff. That strengthens the case for inclusion in DAWG, IMO.

Best,
Kendall Clark

Andrew said...

I don't even want to try and defend the syntax for walk and trans. A lot of iTQL syntax becomes either magical predicates or some sort of function.

I'm pretty sick of syntax wars.

I've been talking to the members of Tucana that are on the DAWG about trans and walk so hopefully they will give you their opinions on it. I think someone wants to put it in the FROM clause.