Skip to content

Commit

Permalink
add self-join and union on build join side test queries
Browse files Browse the repository at this point in the history
  • Loading branch information
bmyerz committed Feb 25, 2014
1 parent df63082 commit f0a2fa5
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions examples/test_query.py
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@ def testEmit(query, name, algebra):
("A(s1) :- T1(s1), s1>0, s1<10", "select_conjunction"),
("A(s1,s2) :- T2(s1,s2), s>10, s2>10", "two_var_select"),
("A(s1,o2) :- T3(s1,p1,o1), R3(o2,p1,o2)", "join"),
("A(a,b) :- R2(a,b), R2(a,c)", "self_join"),
("A(a,b,c) :- R2(a,b), S2(b,c)", "two_path"),
("A(a,c) :- R2(a,b), S2(b,c)", "two_hop"),
("A(a,b,c) :- R2(a,b), S2(b,c), T2(c,d)", "three_path"),
Expand Down Expand Up @@ -73,6 +74,10 @@ def testEmit(query, name, algebra):
("""A(s1,s2) :- T1(s1,s2)
A(s1,s2) :- R1(s1,s2)
B(s1) :- A(s1,s2), S1(s1)""", "union_then_join"),

("""A(s1,s2) :- T1(s1,s2)
A(s1,s2) :- R1(s1,s2)
B(s1) :- A(s1,s2), A(s1,s3)""", "join_of_two_unions"),

("""A(author) :- R(erdoes, 'rdf:type', 'foaf:Person'),
R(doc, 10, erdoes),
Expand Down

0 comments on commit f0a2fa5

Please sign in to comment.