query doesn't work
Posted by
Pakbi on
URL: http://owlready.306.s1.nabble.com/query-doesn-t-work-tp2963.html
Hi guys, the queries doesn't work.
with onto3:
class farmaco(Thing):
pass
for i in farmaco.direct_instances():
querys = list(my_world.sparql('''PREFIX onto: <
http://test.org/codifa.owl#>
SELECT ?q { onto:''' + i.name + ''' onto:contiene ?q
?q onto:interazione onto:''' + PA + ''' .}'''))
for y in querys:
print(y)
controllo1 = 1
querys2 = list(my_world.sparql('''PREFIX onto: <
http://test.org/codifa.owl#>
SELECT ?q { ?q onto:contiene onto:'''+ y + ''' .}'''))
for yy in querys2:
print(yy)
farmaci_incompatibili.append(yy)