Uploaded image for project: 'Blazegraph (by SYSTAP)'
  1. Blazegraph (by SYSTAP)
  2. BLZG-913

Query solutions are duplicated and increase by adding graph patterns

    XMLWordPrintable

    Details

      Description

      Given the following data:

      @prefix : <http://example.com/data/> .   
      @prefix base: <http://example.com/> .
      
      base:graph1
      {
      :person3                                                                                  
          a :Person ; 
          :age 3;                                                                     
          :name "Person 3 - graph1".
          
                                                                                        
      }
      
      base:graph2
      {
      :person3                                                                                  
          a :Person ; 
          :age 13;                                                                     
          :name "Person 3".
      }
      

      and the query:

      PREFIX  rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
      PREFIX  rdfs: <http://www.w3.org/2000/01/rdf-schema#>
      PREFIX  xsd: <http://www.w3.org/2001/XMLSchema#>
      
      select  ?ps ?p ?o
      where { 
              GRAPH <http://example.com/graph1>
              {
                      ?ps ?p ?o.
                      select ?ps
                      where  
                      {
                              ?ps a  <http://example.com/data/Person>. 
                              BLZG-208 ?ps <http://example.com/data/age> ?age.
                              BLZG-209 ?ps <http://example.com/data/name> ?name.
                      }
              }
      }
      order by ?ps
      

      The result is triples for "Person 3
      - graph1" duplicated 3 times (9 triples). Further uncommenting BLZG-208, BLZG-209 reuslts in 6 and 12 triples.
      So the solutions increase by adding graph patterns.

      Expected result would be triples for selected person without the need to use distinct.

        Attachments

          Activity

            People

            Assignee:
            michaelschmidt michaelschmidt
            Reporter:
            eugenforascu eugenforascu
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved: