zazuko / xrm

A friendly language for mappings to RDF
MIT License
1 stars 0 forks source link

Classes in `vocabulary.xrm` cannot be numbers? #155

Closed oschihin closed 1 month ago

oschihin commented 1 month ago

Hi I am adding a new vocabulary to the vocabulary.xrm, it is rdact: http://rdaregistry.info/termList/RDACarrierType, used to declare the carrier of documentary material. Its classes are skos-Concepts in the form of numbers, so rdact:1018 is "online ressource". Adding this results in an error (mismatched input '1018' expecting RULE_BLOCK_END(org.eclipse.xtext.diagnostics.Diagnostic.Syntax)

Image

Any ideas?

mchlrch commented 1 month ago

Hi @oschihin

In this case, you need to alias the number, for example like this:

classes
  _1018 "1018"

Then in the mapping use the alias identifier _1018:

types
  rdact._1018
oschihin commented 1 month ago

@mchlrch ah thanks, forgot about aliasing. But anyway, please note in the documentation that numbers need to be aliased. Closing here.