Closed GoogleCodeExporter closed 9 years ago
Sorry for the delay in answering your problem report. The mail with your issue
report had been moved by an automatic rule into a wrong mail folder.
When trying to reproduce the problem by passing the query containing the
"count(?artist)" segment to the sparkle-g processor, the following error
message is emitted:
line 4:28 extraneous input 'count' expecting {FROM, WHERE, VAR1, VAR2, '(', '{'}
line 4:41 mismatched input ')' expecting AS
The SPARQL grammar definition for the select clause is defined as
SelectClause ::= 'SELECT' ( 'DISTINCT' | 'REDUCED' )? ( ( Var | ( '('
Expression 'AS' Var ')' ) )+ | '*' )
The "count(?artist)" part of the query should therefore be written as
"(count(?artist) AS ?artistCount)".
This query is accepted by the sparkle-g processor and emitted reformatted
without error.
PREFIX skos: <http://www.w3.org/2004/02/skos/core#>
PREFIX p: <http://dbpedia.org/property/>
SELECT DISTINCT ?uri
?label
(Count(?artist) AS ?artistCount)
WHERE {
<http://dbpedia.org/resource/Alternative_rock> p:associatedActs ?uri .
?artist p:associatedActs ?uri .
?uri rdfs:label ?label
FILTER(Lang(?label) = 'en')
}
Nevertheless the relevant source code for this issue had been restructured.
Any remarks or questions are welcome!
Original comment by Juergen....@gmail.com
on 26 Aug 2012 at 12:24
Original issue reported on code.google.com by
mariano....@gmail.com
on 14 Aug 2012 at 10:12