You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@marmotta.apache.org by Rob Atkinson <ro...@metalinkage.com.au> on 2016/06/03 06:07:48 UTC

UNION support bug

Hi

(although I previously created a couple of issues I dont seem to be able to
create one now - no option on dashboard.)


Anyway I have a query that is valid and works against Sesame that Marmotta
3.3 complains about:

PREFIX  dcterms: <http://purl.org/dc/terms/>
PREFIX  rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX  void: <http://rdfs.org/ns/void#>
PREFIX  rdf:  <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
PREFIX  lid:  <http://id.sirf.net/def/schema/lid/>

SELECT *
WHERE
  {   { { <http://resources.opengeospatial.org/def/voc/examples/mdg>
rdf:type ?___0 }
        OPTIONAL
     { { ?___0 rdfs:label ?___1 } }
      }
    UNION
      { <http://resources.opengeospatial.org/def/voc/examples/mdg>
rdfs:label ?___2 }
    UNION
      { <http://resources.opengeospatial.org/def/voc/examples/mdg>
void:sparqlendpoint ?___10 }
    }

If you remove any one of the UNION clauses it works.

The error comes from the underlying postGres:
org.openrdf.query.QueryEvaluationException:
org.postgresql.util.PSQLException: ERROR: each UNION query must have the
same number of columns

maybe this is an openrdf problem - but it works fine under Sesame - so
maybe its a version thing?

Cheers

Re: UNION support bug

Posted by Rob Atkinson <ro...@metalinkage.com.au>.
Will do asap. Good stuff!

On Sat, 11 Jun 2016 2:43 pm Sergio Fernández <wi...@apache.org> wrote:

> Rob, I fixed MARMOTTA-640 on a topic branch. Could please you give a try to
> 3.4.0-SNAPSHOT from https://github.com/apache/marmotta/tree/MARMOTTA-640
> to
> confirm it before we merging into develop?
> Thanks.
>
> On Sat, Jun 4, 2016 at 1:49 AM, Rob Atkinson <ro...@metalinkage.com.au>
> wrote:
>
> > Thanks!
> >
> > For your information I am working with an international standards
> > organisation within a W3C working group (Spatial Data on the Web) and
> have
> > been developing prrof-of-concept demonstrators around a range of aspects
> -
> > in a couple of weeks I'll be raising awareness of the LDP as a viable
> part
> > of a standards-oriented architecture. In particular, its the reasoning
> that
> > adds a lot of power to this chain - even though its not an LDP concern.
> >
> > So I have a few questions about the reasoning - currently KWRL - this is
> a
> > valid  sKWRL subset? What is the future plan for standards support in the
> > reasoner?
> >
> >  I have developed a set of modules for the Django content management
> > platform that allow for a configurable mapping of managed objects to RDF
> > and LDP containers.
> >
> > https://github.com/rob-metalinkage/django-rdf-io
> >
> > and a SKOS module that exploits this
> > https://github.com/rob-metalinkage/django-skosxl
> >
> > and I've hooked this up to serve the back-end for an existing application
> > (SISSVOC - which provides a Linked Data API for the SKOS data model) -
> its
> > not quite perfect.
> >
> > Cheers
> >
> >
> > On Sat, 4 Jun 2016 at 00:58 Sergio Fernández <wi...@apache.org> wrote:
> >
> > > Thanks. We'll take a look.
> > >
> > > On Fri, Jun 3, 2016 at 3:38 PM, Rob Atkinson <ro...@metalinkage.com.au>
> > > wrote:
> > >
> > > > with postgres it gave the same error as before..
> > > >
> > > > \nCaused by: org.openrdf.query.QueryEvaluationException:
> > > > org.postgresql.util.PSQLException: ERROR: each UNION query must have
> > the
> > > > same number of columns\n  P
> > > >
> > > > https://issues.apache.org/jira/browse/MARMOTTA-640
> > > >
> > > > Rob
> > > >
> > > > On Fri, 3 Jun 2016 at 23:01 Sergio Fernández <wi...@apache.org>
> > wrote:
> > > >
> > > > > Also in PostgreSQL? What was the database you were used with 3.3.0?
> > > > > Please, file a Jira with the details of the bug.
> > > > > Thanks, Rob.
> > > > >
> > > > > On Fri, Jun 3, 2016 at 2:45 PM, Rob Atkinson <
> rob@metalinkage.com.au
> > >
> > > > > wrote:
> > > > >
> > > > > > still fails , but more explicit debugging in the output:
> > > > > >
> > > > > > org.h2.jdbc.JdbcSQLException: Column count does not match; SQL
> > > > > statement:\n
> > > > > >
> > > > > > Caused by: org.h2.jdbc.JdbcSQLException: Column count does not
> > match;
> > > > SQL
> > > > > > statement:
> > > > > > SELECT U1.U1 AS V1, U1.U2 AS V2
> > > > > >  FROM ((SELECT P1.object AS U1, P2.object AS U2, NULL AS U4, NULL
> > AS
> > > U3
> > > > > >  FROM triples P1
> > > > > >  LEFT JOIN
> > > > > >   triples P2 ON (P2.deleted = false
> > > > > >       AND P1.object = P2.subject
> > > > > >       AND P2.predicate = 738710905965015040)
> > > > > >  WHERE P1.deleted = false
> > > > > >       AND P1.subject = 738711452851924992
> > > > > >       AND P1.predicate = 738710906002763776
> > > > > >
> > > > > >  ) UNION (SELECT NULL AS U1, NULL AS U2
> > > > > >  FROM ((SELECT NULL AS U2, P1.object AS U1
> > > > > >  FROM triples P1
> > > > > >  WHERE P1.deleted = false
> > > > > >       AND P1.subject = 738711452851924992
> > > > > >       AND P1.predicate = 738710905965015040
> > > > > >
> > > > > >  ) UNION (SELECT P1.object AS U2, NULL AS U1
> > > > > >  FROM triples P1
> > > > > >  WHERE P1.deleted = false
> > > > > >       AND P1.subject = 738711452851924992
> > > > > >       AND P1.predicate = 738711452872896512
> > > > > >
> > > > > >  )) AS U1
> > > > > >  )) AS U1
> > > > > >
> > > > > > On Fri, 3 Jun 2016 at 20:02 Sergio Fernández <wi...@apache.org>
> > > > wrote:
> > > > > >
> > > > > > > On Fri, Jun 3, 2016 at 10:35 AM, Rob Atkinson <
> > > > rob@metalinkage.com.au>
> > > > > > > wrote:
> > > > > > > >
> > > > > > > > i'm very busy the next few weeks - but if you can point me
> to a
> > > > > > download
> > > > > > > > for the 3.4 snapshot I'll give it a go.
> > > > > > >
> > > > > > >
> > > > > > > Just:
> > > > > > >
> > > > > > > 1) git clone git@github.com:apache/marmotta.git
> > > > > > > 2) cd marmotta/launchers/marmotta-webapp
> > > > > > > 3) mvn tomcat7:run
> > > > > > > 4) configure postgres as db
> > > > > > > 5) make your test
> > > > > > >
> > > > > > > Thanks!
> > > > > > >
> > > > > > >
> > > > > > >
> > > > > > >
> > > > > > > > On Fri, 3 Jun 2016 at 16:52 Sergio Fernández <
> > wikier@apache.org>
> > > > > > wrote:
> > > > > > > >
> > > > > > > > > Maybe it's a bug how our SPARQL engine translate SPARQL
> into
> > > > SQL...
> > > > > > > > > Have you test it against 3.4.0-SNAPSHOT? Please, do it and
> > > file a
> > > > > > jira
> > > > > > > if
> > > > > > > > > it also fails.
> > > > > > > > >
> > > > > > > > > On Fri, Jun 3, 2016 at 8:07 AM, Rob Atkinson <
> > > > > rob@metalinkage.com.au
> > > > > > >
> > > > > > > > > wrote:
> > > > > > > > >
> > > > > > > > > > Hi
> > > > > > > > > >
> > > > > > > > > > (although I previously created a couple of issues I dont
> > seem
> > > > to
> > > > > be
> > > > > > > > able
> > > > > > > > > to
> > > > > > > > > > create one now - no option on dashboard.)
> > > > > > > > > >
> > > > > > > > > >
> > > > > > > > > > Anyway I have a query that is valid and works against
> > Sesame
> > > > that
> > > > > > > > > Marmotta
> > > > > > > > > > 3.3 complains about:
> > > > > > > > > >
> > > > > > > > > > PREFIX  dcterms: <http://purl.org/dc/terms/>
> > > > > > > > > > PREFIX  rdfs: <http://www.w3.org/2000/01/rdf-schema#>
> > > > > > > > > > PREFIX  void: <http://rdfs.org/ns/void#>
> > > > > > > > > > PREFIX  rdf:  <
> http://www.w3.org/1999/02/22-rdf-syntax-ns#
> > >
> > > > > > > > > > PREFIX  lid:  <http://id.sirf.net/def/schema/lid/>
> > > > > > > > > >
> > > > > > > > > > SELECT *
> > > > > > > > > > WHERE
> > > > > > > > > >   {   { { <
> > > > > > http://resources.opengeospatial.org/def/voc/examples/mdg>
> > > > > > > > > > rdf:type ?___0 }
> > > > > > > > > >         OPTIONAL
> > > > > > > > > >      { { ?___0 rdfs:label ?___1 } }
> > > > > > > > > >       }
> > > > > > > > > >     UNION
> > > > > > > > > >       { <
> > > > > http://resources.opengeospatial.org/def/voc/examples/mdg>
> > > > > > > > > > rdfs:label ?___2 }
> > > > > > > > > >     UNION
> > > > > > > > > >       { <
> > > > > http://resources.opengeospatial.org/def/voc/examples/mdg>
> > > > > > > > > > void:sparqlendpoint ?___10 }
> > > > > > > > > >     }
> > > > > > > > > >
> > > > > > > > > > If you remove any one of the UNION clauses it works.
> > > > > > > > > >
> > > > > > > > > > The error comes from the underlying postGres:
> > > > > > > > > > org.openrdf.query.QueryEvaluationException:
> > > > > > > > > > org.postgresql.util.PSQLException: ERROR: each UNION
> query
> > > must
> > > > > > have
> > > > > > > > the
> > > > > > > > > > same number of columns
> > > > > > > > > >
> > > > > > > > > > maybe this is an openrdf problem - but it works fine
> under
> > > > > Sesame -
> > > > > > > so
> > > > > > > > > > maybe its a version thing?
> > > > > > > > > >
> > > > > > > > > > Cheers
> > > > > > > > > >
> > > > > > > > >
> > > > > > > > >
> > > > > > > > >
> > > > > > > > > --
> > > > > > > > > Sergio Fernández
> > > > > > > > > Partner Technology Manager
> > > > > > > > > Redlink GmbH
> > > > > > > > > m: +43 6602747925
> > > > > > > > > e: sergio.fernandez@redlink.co
> > > > > > > > > w: http://redlink.co
> > > > > > > > >
> > > > > > > >
> > > > > > > > --
> > > > > > > > Sergio Fernández
> > > > > > > > Partner Technology Manager
> > > > > > > > Redlink GmbH
> > > > > > > > m: +43 6602747925
> > > > > > > > e: sergio.fernandez@redlink.co
> > > > > > > > w: http://redlink.co
> > > > > > > >
> > > > > > >
> > > > > >
> > > > >
> > > > >
> > > > >
> > > > > --
> > > > > Sergio Fernández
> > > > > Partner Technology Manager
> > > > > Redlink GmbH
> > > > > m: +43 6602747925
> > > > > e: sergio.fernandez@redlink.co
> > > > > w: http://redlink.co
> > > > >
> > > >
> > >
> > >
> > >
> > > --
> > > Sergio Fernández
> > > Partner Technology Manager
> > > Redlink GmbH
> > > m: +43 6602747925
> > > e: sergio.fernandez@redlink.co
> > > w: http://redlink.co
> > >
> >
>
>
>
> --
> Sergio Fernández
> Partner Technology Manager
> Redlink GmbH
> m: +43 6602747925
> e: sergio.fernandez@redlink.co
> w: http://redlink.co
>

Re: UNION support bug

Posted by Sergio Fernández <wi...@apache.org>.
Rob, I fixed MARMOTTA-640 on a topic branch. Could please you give a try to
3.4.0-SNAPSHOT from https://github.com/apache/marmotta/tree/MARMOTTA-640 to
confirm it before we merging into develop?
Thanks.

On Sat, Jun 4, 2016 at 1:49 AM, Rob Atkinson <ro...@metalinkage.com.au> wrote:

> Thanks!
>
> For your information I am working with an international standards
> organisation within a W3C working group (Spatial Data on the Web) and have
> been developing prrof-of-concept demonstrators around a range of aspects -
> in a couple of weeks I'll be raising awareness of the LDP as a viable part
> of a standards-oriented architecture. In particular, its the reasoning that
> adds a lot of power to this chain - even though its not an LDP concern.
>
> So I have a few questions about the reasoning - currently KWRL - this is a
> valid  sKWRL subset? What is the future plan for standards support in the
> reasoner?
>
>  I have developed a set of modules for the Django content management
> platform that allow for a configurable mapping of managed objects to RDF
> and LDP containers.
>
> https://github.com/rob-metalinkage/django-rdf-io
>
> and a SKOS module that exploits this
> https://github.com/rob-metalinkage/django-skosxl
>
> and I've hooked this up to serve the back-end for an existing application
> (SISSVOC - which provides a Linked Data API for the SKOS data model) - its
> not quite perfect.
>
> Cheers
>
>
> On Sat, 4 Jun 2016 at 00:58 Sergio Fernández <wi...@apache.org> wrote:
>
> > Thanks. We'll take a look.
> >
> > On Fri, Jun 3, 2016 at 3:38 PM, Rob Atkinson <ro...@metalinkage.com.au>
> > wrote:
> >
> > > with postgres it gave the same error as before..
> > >
> > > \nCaused by: org.openrdf.query.QueryEvaluationException:
> > > org.postgresql.util.PSQLException: ERROR: each UNION query must have
> the
> > > same number of columns\n  P
> > >
> > > https://issues.apache.org/jira/browse/MARMOTTA-640
> > >
> > > Rob
> > >
> > > On Fri, 3 Jun 2016 at 23:01 Sergio Fernández <wi...@apache.org>
> wrote:
> > >
> > > > Also in PostgreSQL? What was the database you were used with 3.3.0?
> > > > Please, file a Jira with the details of the bug.
> > > > Thanks, Rob.
> > > >
> > > > On Fri, Jun 3, 2016 at 2:45 PM, Rob Atkinson <rob@metalinkage.com.au
> >
> > > > wrote:
> > > >
> > > > > still fails , but more explicit debugging in the output:
> > > > >
> > > > > org.h2.jdbc.JdbcSQLException: Column count does not match; SQL
> > > > statement:\n
> > > > >
> > > > > Caused by: org.h2.jdbc.JdbcSQLException: Column count does not
> match;
> > > SQL
> > > > > statement:
> > > > > SELECT U1.U1 AS V1, U1.U2 AS V2
> > > > >  FROM ((SELECT P1.object AS U1, P2.object AS U2, NULL AS U4, NULL
> AS
> > U3
> > > > >  FROM triples P1
> > > > >  LEFT JOIN
> > > > >   triples P2 ON (P2.deleted = false
> > > > >       AND P1.object = P2.subject
> > > > >       AND P2.predicate = 738710905965015040)
> > > > >  WHERE P1.deleted = false
> > > > >       AND P1.subject = 738711452851924992
> > > > >       AND P1.predicate = 738710906002763776
> > > > >
> > > > >  ) UNION (SELECT NULL AS U1, NULL AS U2
> > > > >  FROM ((SELECT NULL AS U2, P1.object AS U1
> > > > >  FROM triples P1
> > > > >  WHERE P1.deleted = false
> > > > >       AND P1.subject = 738711452851924992
> > > > >       AND P1.predicate = 738710905965015040
> > > > >
> > > > >  ) UNION (SELECT P1.object AS U2, NULL AS U1
> > > > >  FROM triples P1
> > > > >  WHERE P1.deleted = false
> > > > >       AND P1.subject = 738711452851924992
> > > > >       AND P1.predicate = 738711452872896512
> > > > >
> > > > >  )) AS U1
> > > > >  )) AS U1
> > > > >
> > > > > On Fri, 3 Jun 2016 at 20:02 Sergio Fernández <wi...@apache.org>
> > > wrote:
> > > > >
> > > > > > On Fri, Jun 3, 2016 at 10:35 AM, Rob Atkinson <
> > > rob@metalinkage.com.au>
> > > > > > wrote:
> > > > > > >
> > > > > > > i'm very busy the next few weeks - but if you can point me to a
> > > > > download
> > > > > > > for the 3.4 snapshot I'll give it a go.
> > > > > >
> > > > > >
> > > > > > Just:
> > > > > >
> > > > > > 1) git clone git@github.com:apache/marmotta.git
> > > > > > 2) cd marmotta/launchers/marmotta-webapp
> > > > > > 3) mvn tomcat7:run
> > > > > > 4) configure postgres as db
> > > > > > 5) make your test
> > > > > >
> > > > > > Thanks!
> > > > > >
> > > > > >
> > > > > >
> > > > > >
> > > > > > > On Fri, 3 Jun 2016 at 16:52 Sergio Fernández <
> wikier@apache.org>
> > > > > wrote:
> > > > > > >
> > > > > > > > Maybe it's a bug how our SPARQL engine translate SPARQL into
> > > SQL...
> > > > > > > > Have you test it against 3.4.0-SNAPSHOT? Please, do it and
> > file a
> > > > > jira
> > > > > > if
> > > > > > > > it also fails.
> > > > > > > >
> > > > > > > > On Fri, Jun 3, 2016 at 8:07 AM, Rob Atkinson <
> > > > rob@metalinkage.com.au
> > > > > >
> > > > > > > > wrote:
> > > > > > > >
> > > > > > > > > Hi
> > > > > > > > >
> > > > > > > > > (although I previously created a couple of issues I dont
> seem
> > > to
> > > > be
> > > > > > > able
> > > > > > > > to
> > > > > > > > > create one now - no option on dashboard.)
> > > > > > > > >
> > > > > > > > >
> > > > > > > > > Anyway I have a query that is valid and works against
> Sesame
> > > that
> > > > > > > > Marmotta
> > > > > > > > > 3.3 complains about:
> > > > > > > > >
> > > > > > > > > PREFIX  dcterms: <http://purl.org/dc/terms/>
> > > > > > > > > PREFIX  rdfs: <http://www.w3.org/2000/01/rdf-schema#>
> > > > > > > > > PREFIX  void: <http://rdfs.org/ns/void#>
> > > > > > > > > PREFIX  rdf:  <http://www.w3.org/1999/02/22-rdf-syntax-ns#
> >
> > > > > > > > > PREFIX  lid:  <http://id.sirf.net/def/schema/lid/>
> > > > > > > > >
> > > > > > > > > SELECT *
> > > > > > > > > WHERE
> > > > > > > > >   {   { { <
> > > > > http://resources.opengeospatial.org/def/voc/examples/mdg>
> > > > > > > > > rdf:type ?___0 }
> > > > > > > > >         OPTIONAL
> > > > > > > > >      { { ?___0 rdfs:label ?___1 } }
> > > > > > > > >       }
> > > > > > > > >     UNION
> > > > > > > > >       { <
> > > > http://resources.opengeospatial.org/def/voc/examples/mdg>
> > > > > > > > > rdfs:label ?___2 }
> > > > > > > > >     UNION
> > > > > > > > >       { <
> > > > http://resources.opengeospatial.org/def/voc/examples/mdg>
> > > > > > > > > void:sparqlendpoint ?___10 }
> > > > > > > > >     }
> > > > > > > > >
> > > > > > > > > If you remove any one of the UNION clauses it works.
> > > > > > > > >
> > > > > > > > > The error comes from the underlying postGres:
> > > > > > > > > org.openrdf.query.QueryEvaluationException:
> > > > > > > > > org.postgresql.util.PSQLException: ERROR: each UNION query
> > must
> > > > > have
> > > > > > > the
> > > > > > > > > same number of columns
> > > > > > > > >
> > > > > > > > > maybe this is an openrdf problem - but it works fine under
> > > > Sesame -
> > > > > > so
> > > > > > > > > maybe its a version thing?
> > > > > > > > >
> > > > > > > > > Cheers
> > > > > > > > >
> > > > > > > >
> > > > > > > >
> > > > > > > >
> > > > > > > > --
> > > > > > > > Sergio Fernández
> > > > > > > > Partner Technology Manager
> > > > > > > > Redlink GmbH
> > > > > > > > m: +43 6602747925
> > > > > > > > e: sergio.fernandez@redlink.co
> > > > > > > > w: http://redlink.co
> > > > > > > >
> > > > > > >
> > > > > > > --
> > > > > > > Sergio Fernández
> > > > > > > Partner Technology Manager
> > > > > > > Redlink GmbH
> > > > > > > m: +43 6602747925
> > > > > > > e: sergio.fernandez@redlink.co
> > > > > > > w: http://redlink.co
> > > > > > >
> > > > > >
> > > > >
> > > >
> > > >
> > > >
> > > > --
> > > > Sergio Fernández
> > > > Partner Technology Manager
> > > > Redlink GmbH
> > > > m: +43 6602747925
> > > > e: sergio.fernandez@redlink.co
> > > > w: http://redlink.co
> > > >
> > >
> >
> >
> >
> > --
> > Sergio Fernández
> > Partner Technology Manager
> > Redlink GmbH
> > m: +43 6602747925
> > e: sergio.fernandez@redlink.co
> > w: http://redlink.co
> >
>



-- 
Sergio Fernández
Partner Technology Manager
Redlink GmbH
m: +43 6602747925
e: sergio.fernandez@redlink.co
w: http://redlink.co

Re: UNION support bug

Posted by Rob Atkinson <ro...@metalinkage.com.au>.
Thanks!

For your information I am working with an international standards
organisation within a W3C working group (Spatial Data on the Web) and have
been developing prrof-of-concept demonstrators around a range of aspects -
in a couple of weeks I'll be raising awareness of the LDP as a viable part
of a standards-oriented architecture. In particular, its the reasoning that
adds a lot of power to this chain - even though its not an LDP concern.

So I have a few questions about the reasoning - currently KWRL - this is a
valid  sKWRL subset? What is the future plan for standards support in the
reasoner?

 I have developed a set of modules for the Django content management
platform that allow for a configurable mapping of managed objects to RDF
and LDP containers.

https://github.com/rob-metalinkage/django-rdf-io

and a SKOS module that exploits this
https://github.com/rob-metalinkage/django-skosxl

and I've hooked this up to serve the back-end for an existing application
(SISSVOC - which provides a Linked Data API for the SKOS data model) - its
not quite perfect.

Cheers


On Sat, 4 Jun 2016 at 00:58 Sergio Fernández <wi...@apache.org> wrote:

> Thanks. We'll take a look.
>
> On Fri, Jun 3, 2016 at 3:38 PM, Rob Atkinson <ro...@metalinkage.com.au>
> wrote:
>
> > with postgres it gave the same error as before..
> >
> > \nCaused by: org.openrdf.query.QueryEvaluationException:
> > org.postgresql.util.PSQLException: ERROR: each UNION query must have the
> > same number of columns\n  P
> >
> > https://issues.apache.org/jira/browse/MARMOTTA-640
> >
> > Rob
> >
> > On Fri, 3 Jun 2016 at 23:01 Sergio Fernández <wi...@apache.org> wrote:
> >
> > > Also in PostgreSQL? What was the database you were used with 3.3.0?
> > > Please, file a Jira with the details of the bug.
> > > Thanks, Rob.
> > >
> > > On Fri, Jun 3, 2016 at 2:45 PM, Rob Atkinson <ro...@metalinkage.com.au>
> > > wrote:
> > >
> > > > still fails , but more explicit debugging in the output:
> > > >
> > > > org.h2.jdbc.JdbcSQLException: Column count does not match; SQL
> > > statement:\n
> > > >
> > > > Caused by: org.h2.jdbc.JdbcSQLException: Column count does not match;
> > SQL
> > > > statement:
> > > > SELECT U1.U1 AS V1, U1.U2 AS V2
> > > >  FROM ((SELECT P1.object AS U1, P2.object AS U2, NULL AS U4, NULL AS
> U3
> > > >  FROM triples P1
> > > >  LEFT JOIN
> > > >   triples P2 ON (P2.deleted = false
> > > >       AND P1.object = P2.subject
> > > >       AND P2.predicate = 738710905965015040)
> > > >  WHERE P1.deleted = false
> > > >       AND P1.subject = 738711452851924992
> > > >       AND P1.predicate = 738710906002763776
> > > >
> > > >  ) UNION (SELECT NULL AS U1, NULL AS U2
> > > >  FROM ((SELECT NULL AS U2, P1.object AS U1
> > > >  FROM triples P1
> > > >  WHERE P1.deleted = false
> > > >       AND P1.subject = 738711452851924992
> > > >       AND P1.predicate = 738710905965015040
> > > >
> > > >  ) UNION (SELECT P1.object AS U2, NULL AS U1
> > > >  FROM triples P1
> > > >  WHERE P1.deleted = false
> > > >       AND P1.subject = 738711452851924992
> > > >       AND P1.predicate = 738711452872896512
> > > >
> > > >  )) AS U1
> > > >  )) AS U1
> > > >
> > > > On Fri, 3 Jun 2016 at 20:02 Sergio Fernández <wi...@apache.org>
> > wrote:
> > > >
> > > > > On Fri, Jun 3, 2016 at 10:35 AM, Rob Atkinson <
> > rob@metalinkage.com.au>
> > > > > wrote:
> > > > > >
> > > > > > i'm very busy the next few weeks - but if you can point me to a
> > > > download
> > > > > > for the 3.4 snapshot I'll give it a go.
> > > > >
> > > > >
> > > > > Just:
> > > > >
> > > > > 1) git clone git@github.com:apache/marmotta.git
> > > > > 2) cd marmotta/launchers/marmotta-webapp
> > > > > 3) mvn tomcat7:run
> > > > > 4) configure postgres as db
> > > > > 5) make your test
> > > > >
> > > > > Thanks!
> > > > >
> > > > >
> > > > >
> > > > >
> > > > > > On Fri, 3 Jun 2016 at 16:52 Sergio Fernández <wi...@apache.org>
> > > > wrote:
> > > > > >
> > > > > > > Maybe it's a bug how our SPARQL engine translate SPARQL into
> > SQL...
> > > > > > > Have you test it against 3.4.0-SNAPSHOT? Please, do it and
> file a
> > > > jira
> > > > > if
> > > > > > > it also fails.
> > > > > > >
> > > > > > > On Fri, Jun 3, 2016 at 8:07 AM, Rob Atkinson <
> > > rob@metalinkage.com.au
> > > > >
> > > > > > > wrote:
> > > > > > >
> > > > > > > > Hi
> > > > > > > >
> > > > > > > > (although I previously created a couple of issues I dont seem
> > to
> > > be
> > > > > > able
> > > > > > > to
> > > > > > > > create one now - no option on dashboard.)
> > > > > > > >
> > > > > > > >
> > > > > > > > Anyway I have a query that is valid and works against Sesame
> > that
> > > > > > > Marmotta
> > > > > > > > 3.3 complains about:
> > > > > > > >
> > > > > > > > PREFIX  dcterms: <http://purl.org/dc/terms/>
> > > > > > > > PREFIX  rdfs: <http://www.w3.org/2000/01/rdf-schema#>
> > > > > > > > PREFIX  void: <http://rdfs.org/ns/void#>
> > > > > > > > PREFIX  rdf:  <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
> > > > > > > > PREFIX  lid:  <http://id.sirf.net/def/schema/lid/>
> > > > > > > >
> > > > > > > > SELECT *
> > > > > > > > WHERE
> > > > > > > >   {   { { <
> > > > http://resources.opengeospatial.org/def/voc/examples/mdg>
> > > > > > > > rdf:type ?___0 }
> > > > > > > >         OPTIONAL
> > > > > > > >      { { ?___0 rdfs:label ?___1 } }
> > > > > > > >       }
> > > > > > > >     UNION
> > > > > > > >       { <
> > > http://resources.opengeospatial.org/def/voc/examples/mdg>
> > > > > > > > rdfs:label ?___2 }
> > > > > > > >     UNION
> > > > > > > >       { <
> > > http://resources.opengeospatial.org/def/voc/examples/mdg>
> > > > > > > > void:sparqlendpoint ?___10 }
> > > > > > > >     }
> > > > > > > >
> > > > > > > > If you remove any one of the UNION clauses it works.
> > > > > > > >
> > > > > > > > The error comes from the underlying postGres:
> > > > > > > > org.openrdf.query.QueryEvaluationException:
> > > > > > > > org.postgresql.util.PSQLException: ERROR: each UNION query
> must
> > > > have
> > > > > > the
> > > > > > > > same number of columns
> > > > > > > >
> > > > > > > > maybe this is an openrdf problem - but it works fine under
> > > Sesame -
> > > > > so
> > > > > > > > maybe its a version thing?
> > > > > > > >
> > > > > > > > Cheers
> > > > > > > >
> > > > > > >
> > > > > > >
> > > > > > >
> > > > > > > --
> > > > > > > Sergio Fernández
> > > > > > > Partner Technology Manager
> > > > > > > Redlink GmbH
> > > > > > > m: +43 6602747925
> > > > > > > e: sergio.fernandez@redlink.co
> > > > > > > w: http://redlink.co
> > > > > > >
> > > > > >
> > > > > > --
> > > > > > Sergio Fernández
> > > > > > Partner Technology Manager
> > > > > > Redlink GmbH
> > > > > > m: +43 6602747925
> > > > > > e: sergio.fernandez@redlink.co
> > > > > > w: http://redlink.co
> > > > > >
> > > > >
> > > >
> > >
> > >
> > >
> > > --
> > > Sergio Fernández
> > > Partner Technology Manager
> > > Redlink GmbH
> > > m: +43 6602747925
> > > e: sergio.fernandez@redlink.co
> > > w: http://redlink.co
> > >
> >
>
>
>
> --
> Sergio Fernández
> Partner Technology Manager
> Redlink GmbH
> m: +43 6602747925
> e: sergio.fernandez@redlink.co
> w: http://redlink.co
>

Re: UNION support bug

Posted by Sergio Fernández <wi...@apache.org>.
Thanks. We'll take a look.

On Fri, Jun 3, 2016 at 3:38 PM, Rob Atkinson <ro...@metalinkage.com.au> wrote:

> with postgres it gave the same error as before..
>
> \nCaused by: org.openrdf.query.QueryEvaluationException:
> org.postgresql.util.PSQLException: ERROR: each UNION query must have the
> same number of columns\n  P
>
> https://issues.apache.org/jira/browse/MARMOTTA-640
>
> Rob
>
> On Fri, 3 Jun 2016 at 23:01 Sergio Fernández <wi...@apache.org> wrote:
>
> > Also in PostgreSQL? What was the database you were used with 3.3.0?
> > Please, file a Jira with the details of the bug.
> > Thanks, Rob.
> >
> > On Fri, Jun 3, 2016 at 2:45 PM, Rob Atkinson <ro...@metalinkage.com.au>
> > wrote:
> >
> > > still fails , but more explicit debugging in the output:
> > >
> > > org.h2.jdbc.JdbcSQLException: Column count does not match; SQL
> > statement:\n
> > >
> > > Caused by: org.h2.jdbc.JdbcSQLException: Column count does not match;
> SQL
> > > statement:
> > > SELECT U1.U1 AS V1, U1.U2 AS V2
> > >  FROM ((SELECT P1.object AS U1, P2.object AS U2, NULL AS U4, NULL AS U3
> > >  FROM triples P1
> > >  LEFT JOIN
> > >   triples P2 ON (P2.deleted = false
> > >       AND P1.object = P2.subject
> > >       AND P2.predicate = 738710905965015040)
> > >  WHERE P1.deleted = false
> > >       AND P1.subject = 738711452851924992
> > >       AND P1.predicate = 738710906002763776
> > >
> > >  ) UNION (SELECT NULL AS U1, NULL AS U2
> > >  FROM ((SELECT NULL AS U2, P1.object AS U1
> > >  FROM triples P1
> > >  WHERE P1.deleted = false
> > >       AND P1.subject = 738711452851924992
> > >       AND P1.predicate = 738710905965015040
> > >
> > >  ) UNION (SELECT P1.object AS U2, NULL AS U1
> > >  FROM triples P1
> > >  WHERE P1.deleted = false
> > >       AND P1.subject = 738711452851924992
> > >       AND P1.predicate = 738711452872896512
> > >
> > >  )) AS U1
> > >  )) AS U1
> > >
> > > On Fri, 3 Jun 2016 at 20:02 Sergio Fernández <wi...@apache.org>
> wrote:
> > >
> > > > On Fri, Jun 3, 2016 at 10:35 AM, Rob Atkinson <
> rob@metalinkage.com.au>
> > > > wrote:
> > > > >
> > > > > i'm very busy the next few weeks - but if you can point me to a
> > > download
> > > > > for the 3.4 snapshot I'll give it a go.
> > > >
> > > >
> > > > Just:
> > > >
> > > > 1) git clone git@github.com:apache/marmotta.git
> > > > 2) cd marmotta/launchers/marmotta-webapp
> > > > 3) mvn tomcat7:run
> > > > 4) configure postgres as db
> > > > 5) make your test
> > > >
> > > > Thanks!
> > > >
> > > >
> > > >
> > > >
> > > > > On Fri, 3 Jun 2016 at 16:52 Sergio Fernández <wi...@apache.org>
> > > wrote:
> > > > >
> > > > > > Maybe it's a bug how our SPARQL engine translate SPARQL into
> SQL...
> > > > > > Have you test it against 3.4.0-SNAPSHOT? Please, do it and file a
> > > jira
> > > > if
> > > > > > it also fails.
> > > > > >
> > > > > > On Fri, Jun 3, 2016 at 8:07 AM, Rob Atkinson <
> > rob@metalinkage.com.au
> > > >
> > > > > > wrote:
> > > > > >
> > > > > > > Hi
> > > > > > >
> > > > > > > (although I previously created a couple of issues I dont seem
> to
> > be
> > > > > able
> > > > > > to
> > > > > > > create one now - no option on dashboard.)
> > > > > > >
> > > > > > >
> > > > > > > Anyway I have a query that is valid and works against Sesame
> that
> > > > > > Marmotta
> > > > > > > 3.3 complains about:
> > > > > > >
> > > > > > > PREFIX  dcterms: <http://purl.org/dc/terms/>
> > > > > > > PREFIX  rdfs: <http://www.w3.org/2000/01/rdf-schema#>
> > > > > > > PREFIX  void: <http://rdfs.org/ns/void#>
> > > > > > > PREFIX  rdf:  <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
> > > > > > > PREFIX  lid:  <http://id.sirf.net/def/schema/lid/>
> > > > > > >
> > > > > > > SELECT *
> > > > > > > WHERE
> > > > > > >   {   { { <
> > > http://resources.opengeospatial.org/def/voc/examples/mdg>
> > > > > > > rdf:type ?___0 }
> > > > > > >         OPTIONAL
> > > > > > >      { { ?___0 rdfs:label ?___1 } }
> > > > > > >       }
> > > > > > >     UNION
> > > > > > >       { <
> > http://resources.opengeospatial.org/def/voc/examples/mdg>
> > > > > > > rdfs:label ?___2 }
> > > > > > >     UNION
> > > > > > >       { <
> > http://resources.opengeospatial.org/def/voc/examples/mdg>
> > > > > > > void:sparqlendpoint ?___10 }
> > > > > > >     }
> > > > > > >
> > > > > > > If you remove any one of the UNION clauses it works.
> > > > > > >
> > > > > > > The error comes from the underlying postGres:
> > > > > > > org.openrdf.query.QueryEvaluationException:
> > > > > > > org.postgresql.util.PSQLException: ERROR: each UNION query must
> > > have
> > > > > the
> > > > > > > same number of columns
> > > > > > >
> > > > > > > maybe this is an openrdf problem - but it works fine under
> > Sesame -
> > > > so
> > > > > > > maybe its a version thing?
> > > > > > >
> > > > > > > Cheers
> > > > > > >
> > > > > >
> > > > > >
> > > > > >
> > > > > > --
> > > > > > Sergio Fernández
> > > > > > Partner Technology Manager
> > > > > > Redlink GmbH
> > > > > > m: +43 6602747925
> > > > > > e: sergio.fernandez@redlink.co
> > > > > > w: http://redlink.co
> > > > > >
> > > > >
> > > > > --
> > > > > Sergio Fernández
> > > > > Partner Technology Manager
> > > > > Redlink GmbH
> > > > > m: +43 6602747925
> > > > > e: sergio.fernandez@redlink.co
> > > > > w: http://redlink.co
> > > > >
> > > >
> > >
> >
> >
> >
> > --
> > Sergio Fernández
> > Partner Technology Manager
> > Redlink GmbH
> > m: +43 6602747925
> > e: sergio.fernandez@redlink.co
> > w: http://redlink.co
> >
>



-- 
Sergio Fernández
Partner Technology Manager
Redlink GmbH
m: +43 6602747925
e: sergio.fernandez@redlink.co
w: http://redlink.co

Re: UNION support bug

Posted by Rob Atkinson <ro...@metalinkage.com.au>.
with postgres it gave the same error as before..

\nCaused by: org.openrdf.query.QueryEvaluationException:
org.postgresql.util.PSQLException: ERROR: each UNION query must have the
same number of columns\n  P

https://issues.apache.org/jira/browse/MARMOTTA-640

Rob

On Fri, 3 Jun 2016 at 23:01 Sergio Fernández <wi...@apache.org> wrote:

> Also in PostgreSQL? What was the database you were used with 3.3.0?
> Please, file a Jira with the details of the bug.
> Thanks, Rob.
>
> On Fri, Jun 3, 2016 at 2:45 PM, Rob Atkinson <ro...@metalinkage.com.au>
> wrote:
>
> > still fails , but more explicit debugging in the output:
> >
> > org.h2.jdbc.JdbcSQLException: Column count does not match; SQL
> statement:\n
> >
> > Caused by: org.h2.jdbc.JdbcSQLException: Column count does not match; SQL
> > statement:
> > SELECT U1.U1 AS V1, U1.U2 AS V2
> >  FROM ((SELECT P1.object AS U1, P2.object AS U2, NULL AS U4, NULL AS U3
> >  FROM triples P1
> >  LEFT JOIN
> >   triples P2 ON (P2.deleted = false
> >       AND P1.object = P2.subject
> >       AND P2.predicate = 738710905965015040)
> >  WHERE P1.deleted = false
> >       AND P1.subject = 738711452851924992
> >       AND P1.predicate = 738710906002763776
> >
> >  ) UNION (SELECT NULL AS U1, NULL AS U2
> >  FROM ((SELECT NULL AS U2, P1.object AS U1
> >  FROM triples P1
> >  WHERE P1.deleted = false
> >       AND P1.subject = 738711452851924992
> >       AND P1.predicate = 738710905965015040
> >
> >  ) UNION (SELECT P1.object AS U2, NULL AS U1
> >  FROM triples P1
> >  WHERE P1.deleted = false
> >       AND P1.subject = 738711452851924992
> >       AND P1.predicate = 738711452872896512
> >
> >  )) AS U1
> >  )) AS U1
> >
> > On Fri, 3 Jun 2016 at 20:02 Sergio Fernández <wi...@apache.org> wrote:
> >
> > > On Fri, Jun 3, 2016 at 10:35 AM, Rob Atkinson <ro...@metalinkage.com.au>
> > > wrote:
> > > >
> > > > i'm very busy the next few weeks - but if you can point me to a
> > download
> > > > for the 3.4 snapshot I'll give it a go.
> > >
> > >
> > > Just:
> > >
> > > 1) git clone git@github.com:apache/marmotta.git
> > > 2) cd marmotta/launchers/marmotta-webapp
> > > 3) mvn tomcat7:run
> > > 4) configure postgres as db
> > > 5) make your test
> > >
> > > Thanks!
> > >
> > >
> > >
> > >
> > > > On Fri, 3 Jun 2016 at 16:52 Sergio Fernández <wi...@apache.org>
> > wrote:
> > > >
> > > > > Maybe it's a bug how our SPARQL engine translate SPARQL into SQL...
> > > > > Have you test it against 3.4.0-SNAPSHOT? Please, do it and file a
> > jira
> > > if
> > > > > it also fails.
> > > > >
> > > > > On Fri, Jun 3, 2016 at 8:07 AM, Rob Atkinson <
> rob@metalinkage.com.au
> > >
> > > > > wrote:
> > > > >
> > > > > > Hi
> > > > > >
> > > > > > (although I previously created a couple of issues I dont seem to
> be
> > > > able
> > > > > to
> > > > > > create one now - no option on dashboard.)
> > > > > >
> > > > > >
> > > > > > Anyway I have a query that is valid and works against Sesame that
> > > > > Marmotta
> > > > > > 3.3 complains about:
> > > > > >
> > > > > > PREFIX  dcterms: <http://purl.org/dc/terms/>
> > > > > > PREFIX  rdfs: <http://www.w3.org/2000/01/rdf-schema#>
> > > > > > PREFIX  void: <http://rdfs.org/ns/void#>
> > > > > > PREFIX  rdf:  <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
> > > > > > PREFIX  lid:  <http://id.sirf.net/def/schema/lid/>
> > > > > >
> > > > > > SELECT *
> > > > > > WHERE
> > > > > >   {   { { <
> > http://resources.opengeospatial.org/def/voc/examples/mdg>
> > > > > > rdf:type ?___0 }
> > > > > >         OPTIONAL
> > > > > >      { { ?___0 rdfs:label ?___1 } }
> > > > > >       }
> > > > > >     UNION
> > > > > >       { <
> http://resources.opengeospatial.org/def/voc/examples/mdg>
> > > > > > rdfs:label ?___2 }
> > > > > >     UNION
> > > > > >       { <
> http://resources.opengeospatial.org/def/voc/examples/mdg>
> > > > > > void:sparqlendpoint ?___10 }
> > > > > >     }
> > > > > >
> > > > > > If you remove any one of the UNION clauses it works.
> > > > > >
> > > > > > The error comes from the underlying postGres:
> > > > > > org.openrdf.query.QueryEvaluationException:
> > > > > > org.postgresql.util.PSQLException: ERROR: each UNION query must
> > have
> > > > the
> > > > > > same number of columns
> > > > > >
> > > > > > maybe this is an openrdf problem - but it works fine under
> Sesame -
> > > so
> > > > > > maybe its a version thing?
> > > > > >
> > > > > > Cheers
> > > > > >
> > > > >
> > > > >
> > > > >
> > > > > --
> > > > > Sergio Fernández
> > > > > Partner Technology Manager
> > > > > Redlink GmbH
> > > > > m: +43 6602747925
> > > > > e: sergio.fernandez@redlink.co
> > > > > w: http://redlink.co
> > > > >
> > > >
> > > > --
> > > > Sergio Fernández
> > > > Partner Technology Manager
> > > > Redlink GmbH
> > > > m: +43 6602747925
> > > > e: sergio.fernandez@redlink.co
> > > > w: http://redlink.co
> > > >
> > >
> >
>
>
>
> --
> Sergio Fernández
> Partner Technology Manager
> Redlink GmbH
> m: +43 6602747925
> e: sergio.fernandez@redlink.co
> w: http://redlink.co
>

Re: UNION support bug

Posted by Sergio Fernández <wi...@apache.org>.
Also in PostgreSQL? What was the database you were used with 3.3.0?
Please, file a Jira with the details of the bug.
Thanks, Rob.

On Fri, Jun 3, 2016 at 2:45 PM, Rob Atkinson <ro...@metalinkage.com.au> wrote:

> still fails , but more explicit debugging in the output:
>
> org.h2.jdbc.JdbcSQLException: Column count does not match; SQL statement:\n
>
> Caused by: org.h2.jdbc.JdbcSQLException: Column count does not match; SQL
> statement:
> SELECT U1.U1 AS V1, U1.U2 AS V2
>  FROM ((SELECT P1.object AS U1, P2.object AS U2, NULL AS U4, NULL AS U3
>  FROM triples P1
>  LEFT JOIN
>   triples P2 ON (P2.deleted = false
>       AND P1.object = P2.subject
>       AND P2.predicate = 738710905965015040)
>  WHERE P1.deleted = false
>       AND P1.subject = 738711452851924992
>       AND P1.predicate = 738710906002763776
>
>  ) UNION (SELECT NULL AS U1, NULL AS U2
>  FROM ((SELECT NULL AS U2, P1.object AS U1
>  FROM triples P1
>  WHERE P1.deleted = false
>       AND P1.subject = 738711452851924992
>       AND P1.predicate = 738710905965015040
>
>  ) UNION (SELECT P1.object AS U2, NULL AS U1
>  FROM triples P1
>  WHERE P1.deleted = false
>       AND P1.subject = 738711452851924992
>       AND P1.predicate = 738711452872896512
>
>  )) AS U1
>  )) AS U1
>
> On Fri, 3 Jun 2016 at 20:02 Sergio Fernández <wi...@apache.org> wrote:
>
> > On Fri, Jun 3, 2016 at 10:35 AM, Rob Atkinson <ro...@metalinkage.com.au>
> > wrote:
> > >
> > > i'm very busy the next few weeks - but if you can point me to a
> download
> > > for the 3.4 snapshot I'll give it a go.
> >
> >
> > Just:
> >
> > 1) git clone git@github.com:apache/marmotta.git
> > 2) cd marmotta/launchers/marmotta-webapp
> > 3) mvn tomcat7:run
> > 4) configure postgres as db
> > 5) make your test
> >
> > Thanks!
> >
> >
> >
> >
> > > On Fri, 3 Jun 2016 at 16:52 Sergio Fernández <wi...@apache.org>
> wrote:
> > >
> > > > Maybe it's a bug how our SPARQL engine translate SPARQL into SQL...
> > > > Have you test it against 3.4.0-SNAPSHOT? Please, do it and file a
> jira
> > if
> > > > it also fails.
> > > >
> > > > On Fri, Jun 3, 2016 at 8:07 AM, Rob Atkinson <rob@metalinkage.com.au
> >
> > > > wrote:
> > > >
> > > > > Hi
> > > > >
> > > > > (although I previously created a couple of issues I dont seem to be
> > > able
> > > > to
> > > > > create one now - no option on dashboard.)
> > > > >
> > > > >
> > > > > Anyway I have a query that is valid and works against Sesame that
> > > > Marmotta
> > > > > 3.3 complains about:
> > > > >
> > > > > PREFIX  dcterms: <http://purl.org/dc/terms/>
> > > > > PREFIX  rdfs: <http://www.w3.org/2000/01/rdf-schema#>
> > > > > PREFIX  void: <http://rdfs.org/ns/void#>
> > > > > PREFIX  rdf:  <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
> > > > > PREFIX  lid:  <http://id.sirf.net/def/schema/lid/>
> > > > >
> > > > > SELECT *
> > > > > WHERE
> > > > >   {   { { <
> http://resources.opengeospatial.org/def/voc/examples/mdg>
> > > > > rdf:type ?___0 }
> > > > >         OPTIONAL
> > > > >      { { ?___0 rdfs:label ?___1 } }
> > > > >       }
> > > > >     UNION
> > > > >       { <http://resources.opengeospatial.org/def/voc/examples/mdg>
> > > > > rdfs:label ?___2 }
> > > > >     UNION
> > > > >       { <http://resources.opengeospatial.org/def/voc/examples/mdg>
> > > > > void:sparqlendpoint ?___10 }
> > > > >     }
> > > > >
> > > > > If you remove any one of the UNION clauses it works.
> > > > >
> > > > > The error comes from the underlying postGres:
> > > > > org.openrdf.query.QueryEvaluationException:
> > > > > org.postgresql.util.PSQLException: ERROR: each UNION query must
> have
> > > the
> > > > > same number of columns
> > > > >
> > > > > maybe this is an openrdf problem - but it works fine under Sesame -
> > so
> > > > > maybe its a version thing?
> > > > >
> > > > > Cheers
> > > > >
> > > >
> > > >
> > > >
> > > > --
> > > > Sergio Fernández
> > > > Partner Technology Manager
> > > > Redlink GmbH
> > > > m: +43 6602747925
> > > > e: sergio.fernandez@redlink.co
> > > > w: http://redlink.co
> > > >
> > >
> > > --
> > > Sergio Fernández
> > > Partner Technology Manager
> > > Redlink GmbH
> > > m: +43 6602747925
> > > e: sergio.fernandez@redlink.co
> > > w: http://redlink.co
> > >
> >
>



-- 
Sergio Fernández
Partner Technology Manager
Redlink GmbH
m: +43 6602747925
e: sergio.fernandez@redlink.co
w: http://redlink.co

Re: UNION support bug

Posted by Rob Atkinson <ro...@metalinkage.com.au>.
still fails , but more explicit debugging in the output:

org.h2.jdbc.JdbcSQLException: Column count does not match; SQL statement:\n

Caused by: org.h2.jdbc.JdbcSQLException: Column count does not match; SQL
statement:
SELECT U1.U1 AS V1, U1.U2 AS V2
 FROM ((SELECT P1.object AS U1, P2.object AS U2, NULL AS U4, NULL AS U3
 FROM triples P1
 LEFT JOIN
  triples P2 ON (P2.deleted = false
      AND P1.object = P2.subject
      AND P2.predicate = 738710905965015040)
 WHERE P1.deleted = false
      AND P1.subject = 738711452851924992
      AND P1.predicate = 738710906002763776

 ) UNION (SELECT NULL AS U1, NULL AS U2
 FROM ((SELECT NULL AS U2, P1.object AS U1
 FROM triples P1
 WHERE P1.deleted = false
      AND P1.subject = 738711452851924992
      AND P1.predicate = 738710905965015040

 ) UNION (SELECT P1.object AS U2, NULL AS U1
 FROM triples P1
 WHERE P1.deleted = false
      AND P1.subject = 738711452851924992
      AND P1.predicate = 738711452872896512

 )) AS U1
 )) AS U1

On Fri, 3 Jun 2016 at 20:02 Sergio Fernández <wi...@apache.org> wrote:

> On Fri, Jun 3, 2016 at 10:35 AM, Rob Atkinson <ro...@metalinkage.com.au>
> wrote:
> >
> > i'm very busy the next few weeks - but if you can point me to a download
> > for the 3.4 snapshot I'll give it a go.
>
>
> Just:
>
> 1) git clone git@github.com:apache/marmotta.git
> 2) cd marmotta/launchers/marmotta-webapp
> 3) mvn tomcat7:run
> 4) configure postgres as db
> 5) make your test
>
> Thanks!
>
>
>
>
> > On Fri, 3 Jun 2016 at 16:52 Sergio Fernández <wi...@apache.org> wrote:
> >
> > > Maybe it's a bug how our SPARQL engine translate SPARQL into SQL...
> > > Have you test it against 3.4.0-SNAPSHOT? Please, do it and file a jira
> if
> > > it also fails.
> > >
> > > On Fri, Jun 3, 2016 at 8:07 AM, Rob Atkinson <ro...@metalinkage.com.au>
> > > wrote:
> > >
> > > > Hi
> > > >
> > > > (although I previously created a couple of issues I dont seem to be
> > able
> > > to
> > > > create one now - no option on dashboard.)
> > > >
> > > >
> > > > Anyway I have a query that is valid and works against Sesame that
> > > Marmotta
> > > > 3.3 complains about:
> > > >
> > > > PREFIX  dcterms: <http://purl.org/dc/terms/>
> > > > PREFIX  rdfs: <http://www.w3.org/2000/01/rdf-schema#>
> > > > PREFIX  void: <http://rdfs.org/ns/void#>
> > > > PREFIX  rdf:  <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
> > > > PREFIX  lid:  <http://id.sirf.net/def/schema/lid/>
> > > >
> > > > SELECT *
> > > > WHERE
> > > >   {   { { <http://resources.opengeospatial.org/def/voc/examples/mdg>
> > > > rdf:type ?___0 }
> > > >         OPTIONAL
> > > >      { { ?___0 rdfs:label ?___1 } }
> > > >       }
> > > >     UNION
> > > >       { <http://resources.opengeospatial.org/def/voc/examples/mdg>
> > > > rdfs:label ?___2 }
> > > >     UNION
> > > >       { <http://resources.opengeospatial.org/def/voc/examples/mdg>
> > > > void:sparqlendpoint ?___10 }
> > > >     }
> > > >
> > > > If you remove any one of the UNION clauses it works.
> > > >
> > > > The error comes from the underlying postGres:
> > > > org.openrdf.query.QueryEvaluationException:
> > > > org.postgresql.util.PSQLException: ERROR: each UNION query must have
> > the
> > > > same number of columns
> > > >
> > > > maybe this is an openrdf problem - but it works fine under Sesame -
> so
> > > > maybe its a version thing?
> > > >
> > > > Cheers
> > > >
> > >
> > >
> > >
> > > --
> > > Sergio Fernández
> > > Partner Technology Manager
> > > Redlink GmbH
> > > m: +43 6602747925
> > > e: sergio.fernandez@redlink.co
> > > w: http://redlink.co
> > >
> >
> > --
> > Sergio Fernández
> > Partner Technology Manager
> > Redlink GmbH
> > m: +43 6602747925
> > e: sergio.fernandez@redlink.co
> > w: http://redlink.co
> >
>

Re: UNION support bug

Posted by Sergio Fernández <wi...@apache.org>.
On Fri, Jun 3, 2016 at 10:35 AM, Rob Atkinson <ro...@metalinkage.com.au>
wrote:
>
> i'm very busy the next few weeks - but if you can point me to a download
> for the 3.4 snapshot I'll give it a go.


Just:

1) git clone git@github.com:apache/marmotta.git
2) cd marmotta/launchers/marmotta-webapp
3) mvn tomcat7:run
4) configure postgres as db
5) make your test

Thanks!




> On Fri, 3 Jun 2016 at 16:52 Sergio Fernández <wi...@apache.org> wrote:
>
> > Maybe it's a bug how our SPARQL engine translate SPARQL into SQL...
> > Have you test it against 3.4.0-SNAPSHOT? Please, do it and file a jira if
> > it also fails.
> >
> > On Fri, Jun 3, 2016 at 8:07 AM, Rob Atkinson <ro...@metalinkage.com.au>
> > wrote:
> >
> > > Hi
> > >
> > > (although I previously created a couple of issues I dont seem to be
> able
> > to
> > > create one now - no option on dashboard.)
> > >
> > >
> > > Anyway I have a query that is valid and works against Sesame that
> > Marmotta
> > > 3.3 complains about:
> > >
> > > PREFIX  dcterms: <http://purl.org/dc/terms/>
> > > PREFIX  rdfs: <http://www.w3.org/2000/01/rdf-schema#>
> > > PREFIX  void: <http://rdfs.org/ns/void#>
> > > PREFIX  rdf:  <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
> > > PREFIX  lid:  <http://id.sirf.net/def/schema/lid/>
> > >
> > > SELECT *
> > > WHERE
> > >   {   { { <http://resources.opengeospatial.org/def/voc/examples/mdg>
> > > rdf:type ?___0 }
> > >         OPTIONAL
> > >      { { ?___0 rdfs:label ?___1 } }
> > >       }
> > >     UNION
> > >       { <http://resources.opengeospatial.org/def/voc/examples/mdg>
> > > rdfs:label ?___2 }
> > >     UNION
> > >       { <http://resources.opengeospatial.org/def/voc/examples/mdg>
> > > void:sparqlendpoint ?___10 }
> > >     }
> > >
> > > If you remove any one of the UNION clauses it works.
> > >
> > > The error comes from the underlying postGres:
> > > org.openrdf.query.QueryEvaluationException:
> > > org.postgresql.util.PSQLException: ERROR: each UNION query must have
> the
> > > same number of columns
> > >
> > > maybe this is an openrdf problem - but it works fine under Sesame - so
> > > maybe its a version thing?
> > >
> > > Cheers
> > >
> >
> >
> >
> > --
> > Sergio Fernández
> > Partner Technology Manager
> > Redlink GmbH
> > m: +43 6602747925
> > e: sergio.fernandez@redlink.co
> > w: http://redlink.co
> >
>
> --
> Sergio Fernández
> Partner Technology Manager
> Redlink GmbH
> m: +43 6602747925
> e: sergio.fernandez@redlink.co
> w: http://redlink.co
>

Re: UNION support bug

Posted by Rob Atkinson <ro...@metalinkage.com.au>.
Hi Sergio,
i'm very busy the next few weeks - but if you can point me to a download
for the 3.4 snapshot I'll give it a go.

Rob

On Fri, 3 Jun 2016 at 16:52 Sergio Fernández <wi...@apache.org> wrote:

> Maybe it's a bug how our SPARQL engine translate SPARQL into SQL...
> Have you test it against 3.4.0-SNAPSHOT? Please, do it and file a jira if
> it also fails.
>
> On Fri, Jun 3, 2016 at 8:07 AM, Rob Atkinson <ro...@metalinkage.com.au>
> wrote:
>
> > Hi
> >
> > (although I previously created a couple of issues I dont seem to be able
> to
> > create one now - no option on dashboard.)
> >
> >
> > Anyway I have a query that is valid and works against Sesame that
> Marmotta
> > 3.3 complains about:
> >
> > PREFIX  dcterms: <http://purl.org/dc/terms/>
> > PREFIX  rdfs: <http://www.w3.org/2000/01/rdf-schema#>
> > PREFIX  void: <http://rdfs.org/ns/void#>
> > PREFIX  rdf:  <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
> > PREFIX  lid:  <http://id.sirf.net/def/schema/lid/>
> >
> > SELECT *
> > WHERE
> >   {   { { <http://resources.opengeospatial.org/def/voc/examples/mdg>
> > rdf:type ?___0 }
> >         OPTIONAL
> >      { { ?___0 rdfs:label ?___1 } }
> >       }
> >     UNION
> >       { <http://resources.opengeospatial.org/def/voc/examples/mdg>
> > rdfs:label ?___2 }
> >     UNION
> >       { <http://resources.opengeospatial.org/def/voc/examples/mdg>
> > void:sparqlendpoint ?___10 }
> >     }
> >
> > If you remove any one of the UNION clauses it works.
> >
> > The error comes from the underlying postGres:
> > org.openrdf.query.QueryEvaluationException:
> > org.postgresql.util.PSQLException: ERROR: each UNION query must have the
> > same number of columns
> >
> > maybe this is an openrdf problem - but it works fine under Sesame - so
> > maybe its a version thing?
> >
> > Cheers
> >
>
>
>
> --
> Sergio Fernández
> Partner Technology Manager
> Redlink GmbH
> m: +43 6602747925
> e: sergio.fernandez@redlink.co
> w: http://redlink.co
>

Re: UNION support bug

Posted by Sergio Fernández <wi...@apache.org>.
Maybe it's a bug how our SPARQL engine translate SPARQL into SQL...
Have you test it against 3.4.0-SNAPSHOT? Please, do it and file a jira if
it also fails.

On Fri, Jun 3, 2016 at 8:07 AM, Rob Atkinson <ro...@metalinkage.com.au> wrote:

> Hi
>
> (although I previously created a couple of issues I dont seem to be able to
> create one now - no option on dashboard.)
>
>
> Anyway I have a query that is valid and works against Sesame that Marmotta
> 3.3 complains about:
>
> PREFIX  dcterms: <http://purl.org/dc/terms/>
> PREFIX  rdfs: <http://www.w3.org/2000/01/rdf-schema#>
> PREFIX  void: <http://rdfs.org/ns/void#>
> PREFIX  rdf:  <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
> PREFIX  lid:  <http://id.sirf.net/def/schema/lid/>
>
> SELECT *
> WHERE
>   {   { { <http://resources.opengeospatial.org/def/voc/examples/mdg>
> rdf:type ?___0 }
>         OPTIONAL
>      { { ?___0 rdfs:label ?___1 } }
>       }
>     UNION
>       { <http://resources.opengeospatial.org/def/voc/examples/mdg>
> rdfs:label ?___2 }
>     UNION
>       { <http://resources.opengeospatial.org/def/voc/examples/mdg>
> void:sparqlendpoint ?___10 }
>     }
>
> If you remove any one of the UNION clauses it works.
>
> The error comes from the underlying postGres:
> org.openrdf.query.QueryEvaluationException:
> org.postgresql.util.PSQLException: ERROR: each UNION query must have the
> same number of columns
>
> maybe this is an openrdf problem - but it works fine under Sesame - so
> maybe its a version thing?
>
> Cheers
>



-- 
Sergio Fernández
Partner Technology Manager
Redlink GmbH
m: +43 6602747925
e: sergio.fernandez@redlink.co
w: http://redlink.co