Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Query including count() does not work #105

Open
shinobu opened this issue May 13, 2016 · 1 comment
Open

Query including count() does not work #105

shinobu opened this issue May 13, 2016 · 1 comment
Assignees

Comments

@shinobu
Copy link
Contributor

shinobu commented May 13, 2016

While trying to count the triples in my knowledge base , I tried to use

Select (COUNT(*) as ?count) where { ?p ?s ?x.}

this throws the error:

SPARQL Error: [unixODBC][OpenLink][Virtuoso iODBC Driver][Virtuoso Server]SQ074: Line 10: SP030: SPARQL compiler, line 8: syntax error at 'FROM' before '<http://localhost/OntoWiki/index.php/issue75/>' () on querying graph <NULL> with query:
PREFIX ns1: <http://www4.wiwiss.fu-berlin.de/bizer/bsbm/v01/instances/>
PREFIX ns0: <http://www4.wiwiss.fu-berlin.de/bizer/bsbm/v01/vocabulary/>
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>

Select
FROM <http://localhost/OntoWiki/index.php/issue75/>
where { ?p ?s ?x.} LIMIT 20

the query does work in Virtuoso.

@shinobu
Copy link
Contributor Author

shinobu commented Jun 20, 2016

update:
the error actually comes from the extra parentheses around the Count, i'm not sure if the parentheses are actually allowed their or not though.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants