The bad syntax was my mistake. I was editing his example in Eclipse, and while 
testing with SELECT instead of DESCRIBE as he suggested, I probably introduced 
that typo and forgot to put DESCRIBE back there.
Thanks for the detailed explanation Andy! :) 
Bruno
 
      From: Andy Seaborne <[email protected]>
 To: [email protected] 
 Sent: Thursday, November 27, 2014 6:35 AM
 Subject: Re: Valid JSON keys in SPARQL endpoint response for Describe queries
   
On 27/11/14 02:02, Bruno P. Kinoshita wrote:
>
> Hello Andy!
>
> The more I learn, the more I realize how little I know :)

:-)

> I think his code's gist expired, but FWIW here is another gist from my local 
> copy [1].
> Thank you!Bruno
> [1] https://gist.github.com/kinow/f36c7cf989a4ee1b5478

?? Bad syntax!

"selectan" not "select"

and it calls execSelect, not execDescribe.  May be that is why they 
force "format="

The original had "describe *", does not mention ?s ?p ?o and got back a 
result set with (?s, ?p, ?o) so it looks like the query was issued with 
the override: format=application/sparql-results+json so the far did do 
something plausible, although asking for a graph and setting "accept" to 
a result set format has a HTTP status code of 406. (How does the caller 
know it's (?s, ?p, ?o) otherwise?)

The default accept header for a model (CONSTRUCT or DESCRIBE)

text/turtle, application/n-triples, application/rdf+xml;q=0.9, 
application/turtle;q=0.8, application/x-turtle;q=0.8, text/rdf+n3;q=0.7, 
application/n3;q=0.6, text/n3;q=0.6, text/plain;q=0.5, */*;q=0.1

which does not mention JSON but does have */*.  The format= overrides that.

(note to selves - add JSON-LD, remove N3).



    Andy



   

Reply via email to