description: Identifier holding a danish [CVR](https://datacvr.virk.dk/data/) number. package_name: hl7.fhir.dk.core derivation: constraint name: CVRIdentifier type: Identifier elements: use: pattern: {type: Code, value: official} index: 0 system: pattern: {type: Uri, value: 'http://cvr.dk'} index: 1 value: constraint: CVR-length: {human: CVR must be exactly 8 numeric characters long, source: 'http://hl7.dk/fhir/core/StructureDefinition/dk-core-cvr-identifier', severity: error, expression: 'value.matches(''^[0-9]{8}$'')'} CVR-modulus-11: human: CVR must pass the modulus 11 check source: http://hl7.dk/fhir/core/StructureDefinition/dk-core-cvr-identifier severity: error expression: |- (( (value.substring(0,1).toInteger()*2)+ (value.substring(1,1).toInteger()*7)+ (value.substring(2,1).toInteger()*6)+ (value.substring(3,1).toInteger()*5)+ (value.substring(4,1).toInteger()*4)+ (value.substring(5,1).toInteger()*3)+ (value.substring(6,1).toInteger()*2)+ (value.substring(7,1).toInteger()*1)) mod(11)=0) index: 2 package_version: 1.1.0 class: complex-type kind: complex-type url: http://hl7.dk/fhir/core/StructureDefinition/dk-core-cvr-identifier base: http://hl7.org/fhir/StructureDefinition/Identifier version: 1.1.0 required: [value, system]