Thank you, that already helps a lot.
It is not _quite_ what we had in mind, though.
While `unionDefaultGraph` makes the default graph a union of all the
named graphs, we then no longer can query data from the actual default
graph.
Assuming we add three people, two of them in named graphs:
ex:Alice a foaf:Person
GRAPH ex:graph1 { ex:Bob a foaf:Person }
GRAPH ex:graph2 { ex:Carl a foaf:Person }
When we run the query
SELECT * WHERE { ?person a foaf:Person }
without `unionDefaultGraph` we only get `ex:Alice`.
with `unionDefaultGraph` we get `ex:Bob` and `ex:Carl`.
We would like to get _all three_ people as a result, i.e. a union of
the default graph and all the named graphs.
Kevin
On Tue, 2021-07-13 at 09:41 +0100, Andy Seaborne wrote:
> Hi Kevin,
>
> The configuration setting you are looking for is "union default graph"
>
> With this, the default graph of the dataset is a view of the union of
> all the named graphs.
>
> for TDB2 (TDB1 is similar), the server configuration would include
> something like:
>
> :dataset_tdb2 rdf:type tdb2:DatasetTDB2 ;
> tdb2:location "DB2" ;
> tdb2:unionDefaultGraph true ;
> .
>
> Andy
>
> https://jena.apache.org/documentation/tdb2/tdb2_fuseki.html
>
> On 13/07/2021 06:35, Perry, Kevin wrote:
> > Hi!
> >
> > We're currently extending an application using both Metaphactory and
> > Blazegraph to also support Jena, or more specifically Fuseki.
> >
> > In a perfect world, we'd be using the exact same SPARQL queries for
> > both Fuseki and Blazegraph.
> > Unfortunately we hit a bit of a snag when it comes to the handling of
> > the default and named graphs[1].
> >
> > We are used to not including a GRAPH clause in our queries and
> > receiving results from all graphs (i.e. both from the default and
> > named
> > graphs).
> > With Fuseki, we only get results from either the default graph or any
> > named graph matching a GRAPH clause.
> >
> > Is there some *configuration setting* (or maybe something equally
> > trivial) to have Fuseki behave similarly to Blazegraph in this
> > respect?
> > At least according to the article[1], there is supposed to be a
> > setting
> > ("[...] Apache Jena offer options to change their default behavior"),
> > but it unfortunately doesn't go into more detail.
> >
> > On the long run, we do intend to rework the queries and how we store
> > data (i.e. putting everything into named graphs) but unfortunately
> > that's not something we can afford to do right away.
> >
> > Kevin
> >
> > [1]https://blog.metaphacts.com/the-default-graph-demystified
> >