Hi All,
I'm presently importing JSON records into a blank database, following Stardog docs.
I created my own SMS2 mapping, please see the test record and mapping below.
I checked stardog.log and starrocks.log and no sign of error details.
Here's the error writren in the terminal.
Thanks for your help in analyzing my error.
Best,
Stéphane
=====================================================================
Error importing file 'test4.json'. Encountered " "." ". "" at line 0, column 0.
Was expecting one of:
"(" ...
"{" ...
"[" ...
"<<" ...
...
...
"true" ...
"false" ...
<Q_IRI_REF> ...
<PNAME_NS> ...
<PNAME_LN> ...
<BLANK_NODE_LABEL> ...
...
...
...
<INTEGER_POSITIVE> ...
<INTEGER_NEGATIVE> ...
...
<DECIMAL_POSITIVE> ...
<DECIMAL_NEGATIVE> ...
...
<DOUBLE_POSITIVE> ...
<DOUBLE_NEGATIVE> ...
<STRING_LITERAL1> ...
<STRING_LITERAL2> ...
<STRING_LITERAL_LONG1> ...
<STRING_LITERAL_LONG2> ...
=====================================================================
{
"id": "2uy3g24ku3y42gku3y42g3",
"title": "This is a title",
"paperAbstract": "",
"authors": [
{
"name": "B Bougie",
"ids": [
"23423424"
]
},
{
"name": "W Parker",
"ids": [
"34534534"
]
}
],
"inCitations": ,
"outCitations": ,
"year": 2019,
"s2Url": "",
"sources": ,
"pdfUrls": ,
"venue": "",
"journalName": "",
"journalVolume": "19",
"journalPages": "45-54",
"doi": "",
"doiUrl": "",
"pmid": "",
"fieldsOfStudy": [
"Computer Science"
],
"magId": "3000193832",
"s2PdfUrl": "",
"entities":
}
=====================================================================
PREFIX : https://localhost/
MAPPING urn:articles
FROM JSON {
"id": "?id",
"title": "?title",
"paperAbstract": "?paperAbstract",
"authors": [ "?authors", {"name": "?name","ids": ["?ids"]},],
"inCitations": [?inCitations],
"outCitations": [?outCitations],
"year": "?year",
"s2Url": "?s2Url",
"sources": [?sources],
"pdfUrls": [?pdfUrls],
"venue": "?venue",
"journalName": "?journalName",
"journalVolume": "?journalVolume",
"journalPages": "?journalPages",
"doi": "?doi",
"doiUrl": "?doiUrl",
"pmid": "?pmid",
"fieldsOfStudy": ["?fieldsOfStudy"],
"magId": "?magId",
"s2PdfUrl": "?s2PdfUrl",
"entities": [?entities]
}
TO {
?article a :Article ;
:id ?id;
:idIndex ?idIndex;
:title ?title;
:paperAbstract ?paperAbstract;
:authoredBy ?authoredBy;
:papers ?papers;
:inCitations ?inCitations;
:outCitations ?outCitations;
:year ?year;
:s2Url ?s2Url;
:sources ?sources;
:pdfUrls ?pdfUrls;
:venueAt ?venueAt;
:journalIn ?journalIn;
:journalInVol ?journalInVol;
:journalPages ?journalPages;
:doi ?doi;
:doiUrl ?doiUrl;
:pmid ?pmid;
:fieldsOfStudyIn ?fieldsOfStudyIn;
:magId ?magId;
:s2PdfUrl ?s2PdfUrl;
:entities ?entities.
?idIndex a :IdIndex ;
:index ?id .
?authoredBy a :AuthoredBy;
:name ?name;
:ids ?ids.
?papers a :papers;
:ids ?ids;
:id ?id.
?ids a :Person .
?fieldsOfStudyIn a :FieldsOfStudyIn;
:fieldsOfStudy.
?venueAt a :VenueAt;
:venue ?venue.
?journalIn a :JournalIn;
:journalName ?journalName.
?journalInVol a :JournalInVol;
:journalName ?journalName;
:journalVolume ?journalVolume.
}
WHERE {
BIND (xsd:date(?year) AS ?xsdYear)
BIND (template("localhost/articles/article_{id}") AS ?article)
BIND (template("localhost/articles/author_{ids}") AS ?authoredBy)
BIND (template("localhost/articles/author_article_{ids}{id}") AS ?papers)
BIND (template("localhost/articles/venue{venue}") AS ?venueAt)
BIND (template("localhost/articles/journal_{journalName}") AS ?journalIn)
BIND (template("localhost/articles/volume_{journalName}{journalVol}") AS ?journalInVol)
BIND (template("localhost/articles/field{fieldsOfStudy}") AS ?fieldsOfStudyIn)
}
=====================================================================