Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Mapping of XML / random #56

Open
psiotwo opened this issue Nov 16, 2023 · 0 comments
Open

Mapping of XML / random #56

psiotwo opened this issue Nov 16, 2023 · 0 comments

Comments

@psiotwo
Copy link

psiotwo commented Nov 16, 2023

I am trying to map an XML nested list (full example attached):

<person>
   <identifier>1</identifier>
   <address>
       <type>email</type>
       <value>[email protected]</value>
   </address>
   <address>
       <type>phone</type>
       <value>+12345</value>
   </address>
       ...

to produce RDF of the form

:person-1 :hasAddress :address-2 .
:address-1 :type "email" .
:address-1 :value "[email protected]" .
:address-2 :type "phone" .
:address-2 :value "+12345" .
...

Addresses don't have any natural well defined identifier (the value/type fields are noisy) so some artificial needs to be crafted. I don't care about their form, so I tried:

  • to automatically generated it using idlab:random, but it does not seem to work because RMLStreamer seems to generate the random ID for each address multiple times - which seems to make it disconnected from the person (as in the attachment)

  • to be derived from the location of the element in XML using some XPath expression.

Neither worked.

Is there any other option to map that XML to RDF in the way suggested?

sample.zip

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant