Hi Andy To use ARQ 2.9.0 I need also to use TDB 0.9 In the new TDB, the function CreateModel(String dir) is no more existing. How to read a model from disc (not from memory) with the new versions?
Thanks a lot Mena ---------------------------------------------------- Mena B. Habib PhD Student University of Twente Faculty of Electrical Engineering, Mathematics and Computer Science. Database Chair 7500AE Enschede, Netherlands mail: [email protected] website: http://wwwhome.ctit.utwente.nl/~badiehm/ Phone: +31 53 489 4549 Fax: +31 53 489 2927 Mobile: +31 68 183 2680 -----Original Message----- From: Andy Seaborne [mailto:[email protected]] On Behalf Of Andy Seaborne Sent: Tuesday, March 13, 2012 1:44 PM To: [email protected] Subject: Re: Loading model into memory On 13/03/12 12:07, [email protected] wrote: > Hi Andy > > I tried this query : > Query query = QueryFactory.create("SELECT * WHERE { > \"http://www.mpii.de/yago/resource/Alexandria\" DISTINCT(path) > \"http://www.mpii.de/yago/resource/Egypt\" } "); But it gives me this error: > Exception in thread "main" com.hp.hpl.jena.query.QueryParseException: > Encountered " "distinct" "DISTINCT "" at line 1, column 64. > > I am using ARQ 2.9.0, Core 2.7.0, TDB 0.9.0 I could not find ARQ > 2.9.1 That query has a number of problems: 1/ DISTINCT(..) is only in the development build of ARQ 2.9.1 (location below). 2/ it's a syntax extension, you need "create(..., Syntax.syntaxARQ)" to enable it 3/ You need to put a path expression inside DISTINCT(...) It does not find arbitrary paths, it matches a path you give it. You can't have variables there either. Not sure that YAGO has for properties. A FOAF example is: ?s distinct(foaf:knows+) ?t although for work-in-progress reasons is the same as ?s foaf:knows+ ?t unlike ARQ 2.9.0 See also this email: http://mail-archives.apache.org/mod_mbox/incubator-jena-users/201203.mbox/%3C4F5A6D38.5070204%40apache.org%3E ARQ 2.9.1 development build: https://repository.apache.org/content/repositories/snapshots/org/apache/jena/jena-arq/2.9.1-incubating-SNAPSHOT/ > > Thanks a lot > > Mena Andy
