Giter Club home page Giter Club logo

joseki's People

Contributors

callidon avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

Forkers

samuell afduarte

joseki's Issues

Convert RDF to a Golang struct

Does this project enables to convert a rdf turtle (TTL file format) to a Golang struct?
I.e. marshal & unmarshal to/from TTL/struct.

Nested select queries return 400 error

Posting the following query to the http://data.linkedmdb.org/sparql endpoint returns a 400 error.

select ?label ?n {
  {
    select ?p (count(?o) as ?n) {
      ?s ?p ?o .
    }
    group by ?s
  }
  bind (replace(str(?s), ".*\\/", "") as ?label)
  filter (?n > 1000)
}
order by ?p

A curl request would look like this:

curl http://data.linkedmdb.org/sparql -X POST --data 'query=select+%3Flabel+%3Fn+%7B%0A++%7B%0A++++select+%3Fp+(count(%3Fs)+as+%3Fn)+%7B%0A++++++%3Fs+%3Fp+%3Fo+.%0A++++%7D%0A++++group+by+%3Fp%0A++%7D%0A++bind+(replace(str(%3Fp)%2C+%22.*%5C%5C%2F%22%2C+%22%22)+as+%3Flabel)%0A++filter+(%3Fn+%3E+1000)%0A%7D%0Aorder+by+%3Fp' -H 'Accept: application/sparql-results+json'

Expected outcome:

The endpoint returns a histogram of predicates, filtered to show only predicates that occur more than 1000 times.

Actual outcome:

The endpoint returns a 400 error with the following headers.

> POST /sparql HTTP/1.1
> Host: data.linkedmdb.org
> User-Agent: curl/7.55.1
> Accept: application/sparql-results+json
> Content-Length: 267
> Content-Type: application/x-www-form-urlencoded
>
} [267 bytes data]
* upload completely sent off: 267 out of 267 bytes
100   267    0     0  100   267      0    267  0:00:01 --:--:--  0:00:01  1265< HTTP/1.1 400 Parse_error__select_label_n_________select_p_counts_as_n________s_p_o___________group_by_p______bind_replacestrp___as_label___filter_n__1000__order_by_p__Encountered_select_at_line_3_column_5_Was_expecting_one_of_____IRIref______PNAME_NS______PNAME_LN______BLANK_NODE_LABEL______VAR1______VAR2______graph______optional______service______filter______true______false______INTEGER______DECIMAL______DOUBLE______INTEGER_POSITIVE______DECIMAL_POSITIVE______DOUBLE_POSITIVE______INTEGER_NEGATIVE______DECIMAL_NEGATIVE______DOUBLE_NEGATIVE______STRING_LITERAL1______STRING_LITERAL2______STRING_LITERAL_LONG1______STRING_LITERAL_LONG2____________NIL________________________ANON______
< Date: Tue, 17 Apr 2018 11:55:02 GMT
< Server: Jetty(6.1.4)
< Pragma: no-cache
< X-Joseki-Server: Joseki-3.0-dev
< Content-Type: text/html; charset=iso-8859-1
< Content-Length: 2387
< Connection: close

To the best of my knowledge, the query is correct.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.