Hi Leykum,

Looking at your instance closely you will see that you have a ?gastric 
interventions? ACTION with a ism_transition current_state as follows:

 

                                    <current_state>

                                                <value>Completed</value>

                                                <defining_code>

                                                            <terminology_id>

                                                                        
<value>532</value>

                                                            </terminology_id>

                                                            
<code_string>openehr</code_string>

                                                </defining_code>

                                    </current_state>

 

You will notice that your terminology_id value is 532 and code_string is 
openehr, which are transposed from what is expected. This occurs again in your 
Diagnosis value in Diagnosis EVALUATION, terminology_id value is C180, 
code_string is ICD10).

 

The Ocean RM validator, which is obviously being used here (I notice the 
invariant message style)  is applying the RM invariants on the TEMINOLOGY_ID 
class that state that the terminology ID must start with a letter and its 
internal RegEx pattern matching used to extract the terminology name from the 
terminology_id value has failed to return a match, which results in a RM 
invariant check on the terminology name to fail. 

 

Although the message is not quite right, having a tight invariant checker 
certainly helps in picking up invalid data even if it is not that obvious that 
it is wrong (some still slip through as will be the case in the diagnosis value 
unless you have a template constraint on the terminology value).

 

Regards

 

Heath

 

From: openehr-technical-bounces at lists.openehr.org 
[mailto:openehr-technical-boun...@lists.openehr.org] On Behalf Of Leykun Melkamu
Sent: Wednesday, 25 April 2012 6:18 PM
To: For open EHR technical discussions
Subject: TerminologyId.Name

 

Hi

 

I was trying to build compositions from xml files and when I try to Commit the 
composition I get the exception TerminologyId.Name must not be null or emtpy.

 

I think the problem is in the xml file corresponding to the  action archetype 
but I don?t know where to set the value for that element. Can I get some 
information from you thanks for your help and time. I have attached the xml 
composition 

 

Best regards ,

Leykun  

 

-------------- next part --------------
An HTML attachment was scrubbed...
URL: 
<http://lists.openehr.org/pipermail/openehr-technical_lists.openehr.org/attachments/20120426/81245c7c/attachment.html>

Reply via email to