I have a .rdf file which I was used for Dgraph in order to import the data and the subsequently queries in order to get the relations in the Dgraph Ratel UI.
Now I need to include in my web application for which Dgraph doesn't have support (link). Hence I started looking for Neo4j.
Can anyone please help out how to import .rdf file in Neo4j if not what's the workaround. Thanks.
Labeled property graph (LPG) and RDF graph are different graph data models, see:
- RDF Triple Stores vs. Labeled Property Graphs: What's the Difference? by Jesus Barrasa
- Reification is red herring by Bob DuCharme
Neo4j supports LPG data model only. However, there is the neosemantics Neo4j plugin.
After installation, say:
CALL semantics.importRDF(<RDF_file_path>, <RDF_serialization_format>)
The mapping from RDF to LPG is described here.
I'd suggest you to use a proper triplestore for RDF data.
来源:https://stackoverflow.com/questions/51837979/how-to-import-rdf-file-in-neo4j-database