From: Richard C. <ri...@cy...> - 2012-01-17 17:09:20
|
Andrea, Beats me. Can you prepare a *minimal* mapping file that exhibits the problem and share it? Just keep cutting out sections until the problem goes away. Best, Richard On 17 Jan 2012, at 15:44, Andrea Splendiani (RRes-Roth) wrote: > Hi, > > I have been using d2rq to map a simple DB to RDF. > When using the ntriples syntax, everything works well. > However, I was using the RDF/XML output to a file, and the system seem to invent triples (or to misplace something anyway). > Is this at all possible ? > The usage of d2rq is a bit borderline, in that it makes lot of constant values which are the same for the same entities. > Also many URIs (that the RDF/XML seems to confuse) differ only from a subset. > > Here is an example of what I get: > > Direct mapping to RDF/XML (dump-rdf) > > <rdf:Description rdf:about="codes/TableB/12/12180/bufr"> > <map2pre:containedIn rdf:resource="codes/TableB/12/12180"/> > <map2pre:containedIn rdf:resource="codes/TableB/12/12180"/> > * <map2pre:containedIn rdf:resource="codes/TableB/12"/> > > <rdfs:label xml:lang="en">Averaged 12 micron BT for all clear pixels at nadir</rdfs:label> > <map2pre:localId>12180</map2pre:localId> > <map2pre:status>http://metoffice.gov.uk/terminology/tools/tableMapping#validStatus</map2pre:status> > <rdfs:description xml:lang="en"></rdfs:description> > <rdf:type rdf:resource="http://metoffice.gov.uk/terminology/tools/tableMapping#codeIndividual"/> > <map2pre:containedIn rdf:resource="codes/TableB/12"/> > <rdfs:label xml:lang="en">Averaged 12 micron BT for all clear pixels at nadir</rdfs:label> > <map2pre:localId>12180</map2pre:localId> > <map2pre:status>http://metoffice.gov.uk/terminology/tools/tableMapping#validStatus</map2pre:status> > <rdfs:description xml:lang="en"></rdfs:description> > <rdf:type rdf:resource="http://metoffice.gov.uk/terminology/tools/tableMapping#codeIndividual"/> > <map2pre:containedIn rdf:resource="codes/TableB"/> > <rdfs:label>Temperature</rdfs:label> > > * R <map2pre:nameSpace>12</map2pre:nameSpace> > * R <map2pre:hasVersion>0_0_0</map2pre:hasVersion> > R <rdf:type rdf:resource="http://metoffice.gov.uk/terminology/tools/tableMapping#codeCollection"/> > R <map2pre:containedIn rdf:resource="codes/TableB"/> > R <rdfs:label>Temperature</rdfs:label> > > > <rdf:type rdf:resource="http://metoffice.gov.uk/terminology/tools/tableMapping#codeCollection"/> > <vocab:BUFR_Unit>K</vocab:BUFR_Unit> > <vocab:BUFR_ReferenceValue rdf:datatype="http://www.w3.org/2001/XMLSchema#int">0</vocab:BUFR_ReferenceValue> > <vocab:BUFR_DataWidth_Bits rdf:datatype="http://www.w3.org/2001/XMLSchema#int">16</vocab:BUFR_DataWidth_Bits> > <vocab:BUFR_Scale rdf:datatype="http://www.w3.org/2001/XMLSchema#int">2</vocab:BUFR_Scale> > <rdf:type rdf:resource="http://metoffice.gov.uk/terminology/tools/tableMapping#standard"/> > <vocab:BUFR_Unit>K</vocab:BUFR_Unit> > <vocab:BUFR_ReferenceValue rdf:datatype="http://www.w3.org/2001/XMLSchema#int">0</vocab:BUFR_ReferenceValue> > <vocab:BUFR_DataWidth_Bits rdf:datatype="http://www.w3.org/2001/XMLSchema#int">16</vocab:BUFR_DataWidth_Bits> > <vocab:BUFR_Scale rdf:datatype="http://www.w3.org/2001/XMLSchema#int">2</vocab:BUFR_Scale> > <rdf:type rdf:resource="http://metoffice.gov.uk/terminology/tools/tableMapping#standard"/> > </rdf:Description> > > Where the R block is repeated forever. > > > If I map to ntriples (dump-rdf) and the than convert to rdfxml (rapper) : > > <ns2897:standard xmlns:ns2897="http://metoffice.gov.uk/terminology/tools/tableMapping#" rdf:about="http://127.0.0.1:8888/MetOffice2/global/codes/TableB/12/12180/bufr"> > <ns2898:BUFR_DataWidth_Bits xmlns:ns2898="http://localhost:7777/MetOffice/global/terminology/" rdf:datatype="http://www.w3.org/2001/XMLSchema#int">16</ns2898:BUFR_DataWidth_Bits> > <ns2899:BUFR_ReferenceValue xmlns:ns2899="http://localhost:7777/MetOffice/global/terminology/" rdf:datatype="http://www.w3.org/2001/XMLSchema#int">0</ns2899:BUFR_ReferenceValue> > <ns2900:BUFR_Scale xmlns:ns2900="http://localhost:7777/MetOffice/global/terminology/" rdf:datatype="http://www.w3.org/2001/XMLSchema#int">2</ns2900:BUFR_Scale> > <ns2901:BUFR_Unit xmlns:ns2901="http://localhost:7777/MetOffice/global/terminology/">K</ns2901:BUFR_Unit> > <ns2897:containedIn rdf:resource="http://127.0.0.1:8888/MetOffice2/global/codes/TableB/12/12180"/> > <rdf:type rdf:resource="http://metoffice.gov.uk/terminology/tools/tableMapping#standard"/> > </ns2897:standard> > > > Now, forget the namespaces, I guess it's rapper way to represent repeated statements. > As you can see, some statements that were in the first version are not in the other (indicated with "*"). > > Any hint on why this may be ? > > best, > Andrea Splendiani > > > > > ------------------------------------------------------------------------------ > Keep Your Developer Skills Current with LearnDevNow! > The most comprehensive online learning library for Microsoft developers > is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, > Metro Style Apps, more. Free future releases when you subscribe now! > http://p.sf.net/sfu/learndevnow-d2d > _______________________________________________ > d2rq-map-devel mailing list > d2r...@li... > https://lists.sourceforge.net/lists/listinfo/d2rq-map-devel |