-
Notifications
You must be signed in to change notification settings - Fork 30
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
dealing with reading/writing to named graphs and the default graph in GraphDB #73
Comments
Can you check https://github.com/ali1k/ld-r/blob/master/services/utils/helpers.js#L170 to see how read/write behavior for GraphDB is defined? |
graphName: 'default'Read query:
update query:
graphName: 'http://www.openrdf.org/schema/sesame#nil'read query:
update query:
|
hmm, I'm exploring GraphDBs way of dealing with NGs and it's pretty confusing at times. A short summary of the behaviour:
My current idea is to add another property for the In case |
Expected Behavior
By correctly setting the
server.js
config, I hope to query and write only to the default graph of my GraphDB instance.Actual Behavior
In the
server.js
config, I first set thegraphName
to'default'
, but this will also make LD-R retrieve triples from named graphs. When writing triples, they end up in the default graph. This is probably the expected behavior of GraphDB (also see this issue). To query the default graph only, I can write queries using the special named graphhttp://www.openrdf.org/schema/sesame#nil
to limit the query to the default graph.However, when I change in the
server.js
config the value ofgraphName
to'http://www.openrdf.org/schema/sesame#nil'
, I don't see any results appearing in LD-R. When making a new resource in LD-R, it is added to the named graphhttp://www.openrdf.org/schema/sesame#nil
. If I try the same query again directly on GraphDB, I don't see the new resource. Only when I specifically query the named graph itself, I can find it:I don't know which queries are send by LD-R, but I guess the read and write queries use
GRAPH
, similar as in the last query. Is it possible to make an exception for GraphDB ifgraphName
equals'http://www.openrdf.org/schema/sesame#nil'
? The read queries should be similar as the first query and the write queries should become something like:(no named graph in write queries, because it should go in the default graph instead of the 'virtual' named graph
http://www.openrdf.org/schema/sesame#nil
)Steps to Reproduce the Problem
Use configs in 'static' mode and run GraphDB locally
Specifications
The text was updated successfully, but these errors were encountered: