This page is part of the FHIR Specification (v0.0.82: DSTU 1). The current version which supercedes this version is 5.0.0. For a full list of available versions, see the Directory of published versions . Page versions: R5 R4B R4 R3 R2

6.13.11 Resource ValueSet - Examples

As well as the specific example below, there are many value sets published as part of defining other resources. See:

Example Index:

General ValueSet ExampleXMLJSON
Codes defined by DICOMXMLJSON
A list of all the URIs defined in the FHIR specXMLJSON

6.13.11.1 General

XML

General ValueSet Example (id = "101")

Raw XML

<ValueSet xmlns="http://hl7.org/fhir">
  <text>
    <status value="generated"/>
    <div xmlns="http://www.w3.org/1999/xhtml">
      <p>Value set &quot;LOINC Codes for Cholesterol&quot;: This is an example value set that includes
         
        all the LOINC codes for serum cholesterol from v2.36. 
        Developed by: FHIR project team (example)</p>
      <p>Published for testing on 13-June 2012</p>
      <p>This is a restriction on
<a href="http://hl7.org/svc/fhir/ValueSet/03acace4-5206-4c8f-a8b4-df27a4c18b09?format=text/html">
        the value set &quot;all serum test codes&quot;</a>, and contains the following LOINC codes:</p>
      <ul>
        <li>14647-2</li>
        <li>2093-3</li>
        <li>35200-5</li>
        <li>9342-7</li>
      </ul>
    </div>
  </text>
  <!--   this example, we elected to use a UUID. We could have used 
     an OID, or a URI - depends on how it will be used.   -->
  <identifier value="256a5231-a2bb-49bd-9fea-f349d428b70d"/>
  <!--   for version, we are going to simply use the day of publication. This is also 
    arbitrary - whatever is here is what people use to refer to the version. 
    Could also be a UUID too   -->
  <version value="20120613"/>
  <!--   set of loinc codes for cholesterol for LONC 2.36   -->
  <name value="LOINC Codes for Cholesterol"/>
  <publisher value="FHIR project team (example)"/>
  <telecom>
    <system value="url"/>
    <value value="http://hl7.org/fhir"/>
  </telecom>
  <description value="This is an example value set that includes        all the LOINC codes for serum cholesterol
   from v2.36"/>
  <status value="draft"/>
  <experimental value="true"/>
  <date value="2012-06-13"/>
  <compose>

    <!--   we claim that this value set is a constraint on this other value set 
    this actual URL is a reference to a fictitious value set definition on a 
    fictitious FHIR value set registry. We claim here, simply for illustrative 
    purposes, that the value set referred to here is all LOINC codes for serum
    tests, and that this value set is therefor a constraint on that one 

     Currently this is not included in the resource pending further investigation
    &lt;restricts value=&quot;http://hl7.org/svc/fhir/ValueSet/03acace4-5206-4c8f-a8b4-df27a4c18b09&
    quot;/&gt;   -->
    <!--   given that this value set is small, it doesn't make 
   sense to import another one - what would it say? But if that made sense, 
   we'd do it like this: 
  &lt;import&gt;http://hl7.org/svc/fhir/ValueSet/f0f65621-ae8c-4c57-9f96-5326c2acefe3&lt;/import&gt;
       -->
    <!--   you could have multiple includes, if you wanted to include codes from more than
     one code system, or include codes with different modes. we don't, in this case   -->
    <include>
      <system value="http://loinc.org"/>
      <version value="2.36"/>
      <!--   for LOINC, we simply include the listed codes - no subsumption in LOINC   -->
      <!--   these were selected by hand   -->
      <code value="14647-2"/>
      <code value="2093-3"/>
      <code value="35200-5"/>
      <code value="9342-7"/>
    </include>
  </compose>
</ValueSet>

JSON

General ValueSet Example

{
  "resourceType": "ValueSet",
  "text": {
    "status": "generated",
    "div": "<div>\n      <p>Value set &quot;LOINC Codes for Cholesterol&quot;: This is an example value set that includes \n        all the LOINC codes for serum cholesterol from v2.36. \n        Developed by: FHIR project team (example)</p>\n      <p>Published for testing on 13-June 2012</p>\n      <p>This is a restriction on\n<a href=\"http://hl7.org/svc/fhir/ValueSet/03acace4-5206-4c8f-a8b4-df27a4c18b09?format=text/html\">\n        the value set &quot;all serum test codes&quot;</a>, and contains the following LOINC codes:</p>\n      <ul>\n        <li>14647-2</li>\n        <li>2093-3</li>\n        <li>35200-5</li>\n        <li>9342-7</li>\n      </ul>\n    </div>"
  },
  "identifier": "256a5231-a2bb-49bd-9fea-f349d428b70d",
  "version": "20120613",
  "name": "LOINC Codes for Cholesterol",
  "publisher": "FHIR project team (example)",
  "telecom": [
    {
      "system": "url",
      "value": "http://hl7.org/fhir"
    }
  ],
  "description": "This is an example value set that includes        all the LOINC codes for serum cholesterol from v2.36",
  "status": "draft",
  "experimental": true,
  "date": "2012-06-13",
  "compose": {
    "include": [
      {
        "system": "http://loinc.org",
        "version": "2.36",
        "code": [
          "14647-2",
          "2093-3",
          "35200-5",
          "9342-7"
        ]
      }
    ]
  }
}

comments powered by Disqus