Christopher Warner Studies and thoughts, usually in coherent fashion.

21Aug/080

SPARQL and still sub-querying

for x in g.query("SELECT ?xcreator WHERE { ?creator dc:creator ?xcreator }",
initNs=ns):

print x

sub_query = "SELECT ?creator WHERE { ?xcreator ?creator }"

for sub_x in g.query(sub_query, initNs=dict(ns)):
print 'Sub_x %s' % sub_x

This can't be the only way to do sub_queries with SPARQL and this doesn't work well for me because the first result is on a blanknode. The stuff is really apart of rdf:seq which I haven't figured out how to get yet even though my namespace is correct. ns#_1 contains all of the Literals for Dublin Core/Exif Metadata. I'm beginning to think maybe the binary tag from ExifTool is wrong or something.

About Christopher Warner

Christopher Warner is part genius, part idiot. This makes him well balanced. He's worked on numerous opensource projects with great people and has generally led an eventful and fulfilling life. He hopes to retire an old man in a rocking chair should he be so fortunate.
Comments (0) Trackbacks (0)

No comments yet.


Leave a comment

You must be logged in to post a comment.

No trackbacks yet.