[ 
https://issues.apache.org/jira/browse/MARMOTTA-651?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15393398#comment-15393398
 ] 

Sergio Fernández commented on MARMOTTA-651:
-------------------------------------------

[[email protected]], could you give a try to the current {{HEAD}} at 
{{develop}}. 

I've just introduced a patch to deal with a JAX-RS issue, and now works for me, 
both with {{curl}} int he command-line:

{code:none}
$ curl -X POST 'http://localhost:8080/sparql/select' -H 'Content-Type: 
text/plain' --data 'CONSTRUCT { ?s ?p ?o }  WHERE { ?s ?p ?o } limit 10'
[ {
  "@graph" : [ {
    "@id" : "http://localhost:8080/ldp";,
    "@type" : [ "http://www.w3.org/ns/ldp#Container";, 
"http://www.w3.org/ns/ldp#Resource";, "http://www.w3.org/ns/ldp#BasicContainer";, 
"http://www.w3.org/ns/ldp#RDFSource"; ],
    "http://purl.org/dc/terms/created"; : [ {
      "@type" : "http://www.w3.org/2001/XMLSchema#dateTime";,
      "@value" : "2016-07-26T09:54:52.000+02:00"
    } ],
    "http://purl.org/dc/terms/modified"; : [ {
      "@type" : "http://www.w3.org/2001/XMLSchema#dateTime";,
      "@value" : "2016-07-26T09:54:52.000+02:00"
    } ],
    "http://www.w3.org/2000/01/rdf-schema#label"; : [ {
      "@value" : "Marmotta's LDP Root Container"
    } ],
    "http://www.w3.org/ns/ldp#interactionModel"; : [ {
      "@id" : "http://www.w3.org/ns/ldp#Container";
    } ]
  } ],
  "@id" : "http://localhost:8080/context/default";
} ]
{code}

and {{SPARQLWrapper}} from Python:

{code:javascript}
>>> from SPARQLWrapper import SPARQLWrapper, POST
>>> sparql = SPARQLWrapper("http://localhost:8080/sparql/select";)
>>> sparql.setMethod(POST)
>>> sparql.setQuery("CONSTRUCT { ?s ?p ?o }  WHERE { ?s ?p ?o } limit 10")
>>> print(len(sparql.query().convert()))
8
{code}

Please, let us know if it also works for you now.

> CONSTRUCT Queries return no results
> -----------------------------------
>
>                 Key: MARMOTTA-651
>                 URL: https://issues.apache.org/jira/browse/MARMOTTA-651
>             Project: Marmotta
>          Issue Type: Bug
>          Components: KiWi Triple Store
>    Affects Versions: 3.3.0
>         Environment: Kiwi with postgres backend - tested with SPARQL wrapper 
> - Sesame returns results, kiwi returns empty set
>            Reporter: Rob Atkinson
>            Assignee: Sergio Fernández
>             Fix For: 3.4.0
>
>   Original Estimate: 1h
>  Remaining Estimate: 1h
>
> a SPARQL CONSTRUCT statement against the KIwi returns empty result sets.
> (even when equivalent SELECT statements return results. )



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to