| conceptid | 132256003 |
|---|---|
| display_ko | 마도니시칠리안 |
| term_ko | 마도니시칠리안 |
| term_en | Madonie-Sicilian pig breed |
| fsn_en | Madonie-Sicilian pig breed (organism) |
| desc_id | 211979015 |
| species_sctid | 78678003 |
| breed_level | 2 |
| is_selectable / is_leaf | 1 / 1 |
| parent_sctid | 78678003 |
| has_ko / active | 1 / 1 |
| effective_time |
{
"species_sctid": "78678003",
"breed_sctid": "132256003",
"breed_unknown": null,
"term_version": "20260925"
}
-- 저장 직전 검증 (셋 다 1 이어야 한다)
SELECT COUNT(*) FROM snomed_concept
WHERE domain='breed' AND conceptid='132256003'
AND species_sctid='78678003' AND active=1;
INSERT INTO emr_patient
(name, species_sctid, breed_sctid, breed_unknown, term_version, created_at)
VALUES ('하루', '78678003', '132256003', NULL, '20260925', NOW());SELECT p.name,
s.display_ko AS species_ko,
COALESCE(b.display_ko,
CONCAT('(', p.breed_unknown, ')')) AS breed_ko
FROM emr_patient p
LEFT JOIN snomed_concept s ON s.conceptid = p.species_sctid
LEFT JOIN snomed_concept b ON b.conceptid = p.breed_sctid
WHERE p.id = :id;
{
"resourceType": "Patient",
"extension": [
{
"url": "http://hl7.org/fhir/StructureDefinition/patient-animal-species",
"valueCodeableConcept": {
"coding": [
{
"system": "http://snomed.info/sct",
"code": "78678003",
"display": "돼지"
}
]
}
},
{
"url": "http://hl7.org/fhir/StructureDefinition/patient-animal-breed",
"valueCodeableConcept": {
"coding": [
{
"system": "http://snomed.info/sct",
"code": "132256003",
"display": "마도니시칠리안"
}
]
}
},
{
"url": "https://anidap.kr/fhir/StructureDefinition/kvet-term-version",
"valueString": "20260925"
}
],
"name": [
{
"text": "하루"
}
]
}is_selectable=1 — 등급 2 품종 · 9 혼합breed_sctid=NULL + breed_unknown. 표시명에 문자열을 넣지 않습니다132619000 코드가 있습니다active=0