You have "PREFIX fedora:  <info:fedora/fedora-system:def/relations-external#> 
." (Note the period at the end.)

That is not correct syntax. PREFIX statements do not end with a period. That's 
what the exception is telling you.

---
A. Soroka
Online Library Environment
the University of Virginia Library




On Mar 18, 2011, at 12:16 PM, Laura delli Paoli wrote:

> Hello everybody!
> I was trying to execute a simple SPARQL query through the web interface 
> (http://localhost:8080/fedora/risearch). I created 3 objects: Demo:2, Demo:3 
> and 
> Demo:4.
> Demo:2 contains this RELS-EXT Datastream:
> <rdf:RDF xmlns:fedora="info:fedora/fedora-system:def/relations-external#" 
> xmlns:myns="http://www.nsdl.org/ontologies/relationships#"; 
> xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"; 
> xmlns:rdfs="http://www.w3.org/2000/01/rdf-schema#";>
>  <rdf:Description rdf:about="info:fedora/Demo:2">
>    <fedora:hasConstituent rdf:resource="info:fedora/Demo:3">
> </fedora:hasConstituent>
>    <fedora:hasConstituent rdf:resource="info:fedora/Demo:4">
> </fedora:hasConstituent>
>  </rdf:Description>
> </rdf:RDF>
> 
> The object Demo:3 has this RELS_EXT datastream:
> 
> <rdf:RDF xmlns:dc="http://purl.org/dc/elements/1.1/"; 
> xmlns:demoOntology="info:fedora/Demo:1#" xmlns:fedora="info:fedora/fedora-
> system:def/relations-external#" 
> xmlns:j.0="http://www.dcs.shef.ac.uk/~ajay/image#"; 
> xmlns:j.1="http://www.dcs.shef.ac.uk/~ajay/image/annotation#"; 
> xmlns:myns="http://www.nsdl.org/ontologies/relationships#"; 
> xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"; 
> xmlns:rdfs="http://www.w3.org/2000/01/rdf-schema#";>
>  <rdf:Description rdf:about="info:fedora/Demo:3">
>    <fedora:isConstituentOf rdf:resource="info:fedora/Demo:2">
> </fedora:isConstituentOf>
>  </rdf:Description>
> </rdf:RDF>
> 
> The RELS-EXT datastream of Demo:4 has a datastream similar to that of Demo:3.
> If I execute this simple query:
> PREFIX fedora:  <info:fedora/fedora-system:def/relations-external#> .
> SELECT ?a 
> FROM <#ri>
> WHERE  ?a <fedora:isConstituentOf> <info:fedora/Demo:2>
> I get this error:
> org.trippi.TrippiException: Encountered "." at line 1, column 69.
> Was expecting one of:
>    "SELECT" ...
>    "PREFIX" ...
>    "construct" ...
>    "describe" ...
>    "ask" ...
> 
>       at org.trippi.impl.mulgara.MulgaraSession.query(MulgaraSession.java:172)
>       at 
> org.trippi.impl.base.ConcurrentTriplestoreReader.findTuples(ConcurrentTriplestor
> eReader.java:79)
>       at 
> org.fcrepo.server.resourceIndex.ResourceIndexImpl.findTuples(ResourceIndexImpl.j
> ava:280)
>       at 
> org.fcrepo.server.resourceIndex.ResourceIndexModule.findTuples(ResourceIndexModu
> le.java:297)
>       at org.trippi.server.TrippiServer.find(TrippiServer.java:119)
>       at org.trippi.server.http.TrippiServlet.doFind(TrippiServlet.java:514)
>       at org.trippi.server.http.TrippiServlet.doGet(TrippiServlet.java:379)
>       at 
> org.fcrepo.server.access.RISearchServlet.doGet(RISearchServlet.java:101)
>       at org.trippi.server.http.TrippiServlet.doGet(TrippiServlet.java:271)
>       at org.trippi.server.http.TrippiServlet.doPost(TrippiServlet.java:576)
>       at javax.servlet.http.HttpServlet.service(HttpServlet.java:641)
>       at javax.servlet.http.HttpServlet.service(HttpServlet.java:722)
>       at 
> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilt
> erChain.java:306)
>       at 
> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.
> java:210)
>       at 
> org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:2
> 40)
>       at 
> org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:1
> 61)
>       at 
> org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.jav
> a:589)
>       at 
> org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:164)
>       at 
> org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:100)
>       at 
> org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:541)
>       at 
> org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:118
> )
>       at 
> org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:383)
>       at 
> org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:243)
>       at 
> org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Pr
> otocol.java:188)
>       at 
> org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Pr
> otocol.java:166)
>       at 
> org.apache.tomcat.util.net.JIoEndpoint$SocketProcessor.run(JIoEndpoint.java:288)
>       at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(Unknown 
> Source)
>       at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
>       at java.lang.Thread.run(Unknown Source)
> Caused by: org.mulgara.parser.MulgaraParserException: Encountered "." at line 
> 1, 
> column 69.
> Was expecting one of:
>    "SELECT" ...
>    "PREFIX" ...
>    "construct" ...
>    "describe" ...
>    "ask" ...
> 
>       at 
> org.mulgara.sparql.SparqlInterpreter.parseQuery(SparqlInterpreter.java:209)
>       at org.trippi.impl.mulgara.MulgaraSession.query(MulgaraSession.java:164)
>       ... 28 more
> Caused by: org.mulgara.sparql.parser.ParseException: Encountered "." at line 
> 1, 
> column 69.
> Was expecting one of:
>    "SELECT" ...
>    "PREFIX" ...
>    "construct" ...
>    "describe" ...
>    "ask" ...
> 
>       at 
> org.mulgara.sparql.parser.SparqlParser.generateParseException(SparqlParser.java:
> 2260)
>       at 
> org.mulgara.sparql.parser.SparqlParser.jj_consume_token(SparqlParser.java:2190)
>       at org.mulgara.sparql.parser.SparqlParser.Query(SparqlParser.java:74)
>       at org.mulgara.sparql.parser.SparqlParser.parse(SparqlParser.java:23)
>       at 
> org.mulgara.sparql.SparqlInterpreter.parseQuery(SparqlInterpreter.java:207)
>       ... 29 more
> 
> 
> ------------------------------------------------------------------------------
> Colocation vs. Managed Hosting
> A question and answer guide to determining the best fit
> for your organization - today and in the future.
> http://p.sf.net/sfu/internap-sfd2d
> _______________________________________________
> Fedora-commons-developers mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/fedora-commons-developers


------------------------------------------------------------------------------
Colocation vs. Managed Hosting
A question and answer guide to determining the best fit
for your organization - today and in the future.
http://p.sf.net/sfu/internap-sfd2d
_______________________________________________
Fedora-commons-developers mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/fedora-commons-developers

Reply via email to