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

Service clause breaks query performance

    XMLWordPrintable

    Details

      Description

      The following query:

      SELECT
              ?item ?itemLabel
      WHERE
      {
      ?item wdt:P31/wdt:P279* wd:Q1651051 .
      ?item wdt:P31 ?instance .
      SERVICE wikibase:label {
            bd:serviceParam wikibase:language "it,en" .
      }
      }
      

      finishes in under a second, and returns ~43 results. However after adding a triple to service clause:

      SELECT
              ?item ?itemLabel
      WHERE
      {
      ?item wdt:P31/wdt:P279* wd:Q1651051 .
      ?item wdt:P31 ?instance .
      SERVICE wikibase:label {
            bd:serviceParam wikibase:language "it,en" .
            ?item rdfs:label ?itemLabel
      }
      }
      

      the query takes over 2 minutes and returns over 10K results. Looks like the optimizer mishandles the triple inside service clause.

        Attachments

          Activity

            People

            Assignee:
            igorkim igorkim
            Reporter:
            stasmalyshev stasmalyshev
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved: