neosemantics icon indicating copy to clipboard operation
neosemantics copied to clipboard

Trying to import RDF/XML export from Protege 3.5

Open wdvasu opened this issue 5 years ago • 3 comments

I am trying to import an RDF/XML export to neo4j from Protege 3.5 via neosemantics to determine whether we want to move forward on our project with RDF/XML and SPARQL or neo4j, neosemantics and Cypher. However when I try to import with

n10s.rdf.import.fetch("file////home/bvasu/Downloads/RDFOutInstances.rdf", "RDF/XML");

I get

terminationStatus "KO" 0 triplesLoaded 0 triplesParsed namespaces null "no protocol: file////home/bvasu/Downloads/RDFOutInstances.rdf"

This is an Ubuntu 16.04 OS. Any suggestions?

Thanks, Bill

wdvasu avatar Jun 28 '20 17:06 wdvasu

Looks like there’s a colon missing in the url? Use file:// followed by an absolute path

Cheers,

JB

JB


From: wdvasu [email protected] Sent: Sunday, June 28, 2020 6:05:29 PM To: neo4j-labs/neosemantics [email protected] Cc: Subscribed [email protected] Subject: [neo4j-labs/neosemantics] Trying to import RDF/XML export from Protege 3.5 (#165)

I am trying to import an RDF/XML export to neo4j from Protege 3.5 via neosemantics to determine whether we want to move forward on our project with RDF/XML and SPARQL or neo4j, neosemantics and Cypher. However when I try to import with

n10s.rdf.import.fetch("file////home/bvasu/Downloads/RDFOutInstances.rdf", "RDF/XML");

I get

terminationStatus "KO" 0 triplesLoaded 0 triplesParsed namespaces null "no protocol: file////home/bvasu/Downloads/RDFOutInstances.rdf"

This is an Ubuntu 16.04 OS. Any suggestions?

Thanks, Bill

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHubhttps://github.com/neo4j-labs/neosemantics/issues/165, or unsubscribehttps://github.com/notifications/unsubscribe-auth/ACMGYFZQRGOG4374CJPJXYDRY5Z5TANCNFSM4OKTVIRQ.

jbarrasa avatar Jun 28 '20 17:06 jbarrasa

Thanks, my bad. I tried lots of combinations that would not work but missed that the : was deleted on the last one I tried. Imports of instance and classes exported from Protege 3.5 now successful. But now another question the imported rdf/xml file begins:

 <!ENTITY a 'http://protege.stanford.edu/system#'>
 <!ENTITY rdf_ 'http://compliance.cybermanageit.com/rdf'>
 <!ENTITY rdfs 'http://www.w3.org/2000/01/rdf-schema#'>

]> <rdf:RDF xmlns:rdf="&rdf;" xmlns:a="&a;" xmlns:rdf_="&rdf_;" xmlns:rdfs="&rdfs;">

However, after the import in namespaces I only see:

{ "rdfs": "http://www.w3.org/2000/01/rdf-schema#", "ns0": "http://protege.stanford.edu/system#", "rdf": "http://www.w3.org/1999/02/22-rdf-syntax-ns#", "ns1": "http://protege.stanford.edu/" }

The rdf_ is ignored. Am I doing something wrong?

Thanks for your very prompt response!

Thanks, Bill

wdvasu avatar Jun 28 '20 17:06 wdvasu

have you solved this problem? thanks

heng-yin avatar Nov 26 '20 02:11 heng-yin