Error with inline SPARQL BASE


(Rodolfo Aguirre) #1

With the following query:

BASE <http://localhost:8083/> SELECT * { ?s ?p ?o }

I get the error:

Error!
{"message":"Encountered \" \"select\" \"SELECT \"\" at line 1, column 31.\nWas expecting one of:\n    <EOF> \n    \";\" ...\n    \"base\" ...\n    \"prefix\" ...\n    \"load\" ...\n    \"clear\" ...\n    \"drop\" ...\n    \"add\" ...\n    \"move\" ...\n    \"copy\" ...\n    \"create\" ...\n    \"insert\" ...\n    \"delete\" ...\n    \"with\" ...\n    ","code":"MalformedQuery"}

It looks like it only accepts <EOF> but it should accept more white spaces as specified in https://www.w3.org/TR/sparql11-query/#rWS


(zachary.whitley) #2

I think that it’s correct

[2]  	Query	  ::=  	Prologue
( SelectQuery | ConstructQuery | DescribeQuery | AskQuery )
ValuesClause

I could be wrong though.


(Pavel Klinov) #3

5.3.3 parses this query OK for me. Looking at the error message it looks like you’re trying to parse a SPARQL Update query, not a SELECT query, and that might be the problem.

Cheers,
Pavel


(zachary.whitley) #4

Didn’t work for me when I tried it with 5.2.0


(Pavel Klinov) #5

OK, I see, it doesn’t work in the command like. We’ll fix it.

Thanks,
Pavel


(zachary.whitley) #6

I ran it in the web console.

…cli did’t like it either.


(Rodolfo Aguirre) #7

I’m using 5.1.0
And also ran it in the web query panel.


(Pavel Klinov) #8

Regardless of this bug nobody should be using the Web console for anything now. It’s deprecated and not supported. Stardog Studio is the replacement for querying.

This bug will be fixed in one of the next releases.

Thanks for the report.

Pavel