Skip to content

Conversation

@YalingPeiS
Copy link
Collaborator

@YalingPeiS YalingPeiS commented Nov 25, 2025

Issue

The smileutil upload-terminology command does not support loading more than one CodeSystem.concept.property value to the TRM_CONCEPT_PROPERTY database table with the same CodeSystem.concept.property.code for a given CodeSystem.concept.

{
  "resourceType" : "CodeSystem",
  "id" : "mycodesystem",
  "url" : "http://example.com/mycodesystem",
  "content" : "complete",
  "concept" : [{
    "code" : "code-a",
    "display" : "Code A",
    "property" : [{
      "code" : "alt_description",
      "valueString" : "code a"
    },{
      "code" : "alt_description",
      "valueString" : "CODE A"
    }]
  }]
}

If the above is loaded through a FHIR endpoint via a POST or PUT request, Smile CDR creates two rows in the TRM_CONCEPT_PROPERTY table. However, only one row is created if loaded using smileutil upload-terminology.

This is problematic as some ValueSet definitions use concept.property values to define their contents.

Cause

During concept property processing, the existing TermConceptProperty was updated when the code exists in the property list which caused its value being overwritten, resulting in loss of the all the previous property entries with the same code.

Fix

Create a TermConceptProperty object for each property.

Closes #7401

@robogary
Copy link
Contributor

Formatting check succeeded!

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

Successfully merging this pull request may close these issues.

Smileutil upload-terminology command does not load all concept properties from CSV file

3 participants