I'm using D2RQ to map relational database to an RDF format. Everything works fine except when I want to do a federated search from another endpoint I'm seeing this in a log file:
Query execution error: com.hp.hpl.jena.sparql.ARQNotImplemented: OpNull
Is it possible to do a federated queries in D2RQ ver 0.8.1?
Thank you
Related
I have an architectural doubt.
I am using the GraphQL as an API provider and I need to develop some API requests to import data from excel and to export data to excel on my project.
Where should I create this using the GraphQL API?
I researched and discovered it is possible to create customized queries and mutations on the GraphQL... In this case...
This should be a query?
This should be a mutation?
Or other thing?
Side note: I am using the GraphQL API on my Ruby on Rails project via the graphql-ruby gem and I am also using the mongoid gem to deal with the database.
Comparing to REST API this is how it should be
REST GrapQL
GET GrapQL Query
POST, PUT, PATCH, DELETE GrapQL Mutation
If you are just querying go for GraphQL Query
If you are modifying the data use Mutations
In your case import should be mutation whereas export can be query
Read more - here
I am designing an API for a prototype project we have created that uses AgensGraph as the graph database. Now that we have a working graph database, we need an API (RESTful or GraphQL) that can be used to query the graph without directly using a cypher query. I am looking into using GraphQL. It appears that Neo4j has a GraphQL to Cypher resolver. Is there a similar way to create a GraphQL API for AgensGraph?
There is nothing that I'm aware but ...
There is a graphql plugin for postgres, and AgensGraph is based on PG
you can fork the neo4j-graphql-js project, and change the driver. This project is a Cypher generator for a GraphQL schema, but it uses Neo4j as a backend.
Otherwise try Neo4j :)
It's my very first time building for the semantic web.
I'm not sure how to create a PHP webpage and connect it to an ontology which I have mapped to a relational database using the Ontop plugin for Protege.
Has the database become rdfstore?
I have tried using the EasyRdf library to connect the PHP to ontology, however it didn't work.
Here is the php code that I tried.
<?php
require 'vendor/autoload.php';
$foaf = new EasyRdf_Graph("http://localhost/proIT.owl");
$foaf->load();
$me = $foaf->primaryTopic();
echo "My name is: ".$me->get('foaf:name')."\n";
?>
There are 2 main problems here:
(1) There is no way to access the mappings you have applied from the Protege Ontop plugin from EasyRDF in PHP. The Protege Ontop plugin enables SPARQL queries over your database from Protege, which is not accessible to EasyRDF. Based on the architecture of Ontop, you need to setup a SPARQL endpoint for Ontop which can be done using Sesame workbench. See Sesame SPARQL Enpoint Installation.
(2) Now you need EasyRDF to access the SPARQL endpoint. In this regard your PHP code is incorrect in that it merely loads the .owl file rather than querying the SPARQL endpoint. See EasyRDF SPARQL query example for an example on how to do a SPARQL query using EasyRDF.
Lastly, as for your question whether the database has become an RDFstore, the answer is NO. Your database is not changed. Rather, the Ontop Protege plugin or the repository for Ontop you configure in Sesame Workbench, provides a SPARQL enabled access layer to your database. I.e., you will still be able to do typical SQL queries to your database through your SQL client.
Looking at data access for a multitenant SaaS database for a UI5 app I have two choices - JSON or OData. OData has some features of interest. However, I have concluded that I cannot use OData because of security issues.
In particular I am concerned that OData is a form of query language. As a very rough comparison this is like a SQL statement being composed at the client and sent to an ODBC server for processing. In a multitenant DB I will separate data between owners using, say, and org_id. If it were a SQL query I would have to include select data from table where org_id=this_tennant and .... If I can discover another tenants org_id then I can use an OData explorer to modify the query and pass into the OData source.
In a JSON data interface I would call a REST method that would mask how the data is accessed, and I would not need to expose secret details such as the org_id token. Granted the JSON / REST approach involves more work.
Or do I misunderstand OData ?
Another similar question was asked some time ago but some time has passed so I shall ask again.
The approach of OData is to define how RESTful APIs can be build. It adds a lot of concepts and conventions (e.g. entity types and sets, URL conventions, common query parameters, request format, batch support...) to plain REST and therefore provides you a standard for building your API.
However, it does not define where your data is coming from, but in most cases it will be database. Of course it would be possible to expose your database tables via an OData service in a generic way, but I would expect that the provider of the framework clearly describes how to handle and protect different tenants.
A more specific answer would require more information about the framework you will use.
I know that neo4j database can be used both as embedded or server.
In neo4j documentation it says that REST API has an endpoint for Cypher queries, so if I issue Cypher query using spring-data-neo4j #Query annotated method, this query is sent to the database, executed on database side and then the result is sent back.
What about traversal API then? If I would submit traversal description using
findAllByTraversal(N startNode, org.neo4j.graphdb.traversal.TraversalDescription traversalDescription)
does it send all traversal description to the server and executes it in server context (so there it is only one HTTP request)?
Traversal API (package org.neo4j.graphdb.traversal) is only available via Java API. To expose your code using traversal API via REST, the recommended way is to wrap it into a unmanaged extension.