CPRN Data Submission Specification

Schema Document Properties

Target Namespacehttp://www.cpresearch.net
Version2.1
Element and Attribute Namespaces
  • Global element and attribute declarations belong to this schema's target namespace.
  • By default, local element declarations belong to this schema's target namespace.
  • By default, local attribute declarations have no namespace.
Schema Composition
This document defines the structure and acceptable values for data submitted to CPRN. An overview of CPRN Data Collection as well as the CPRN Data Submission Specification can be found here: [CPRN Data Collection](https://cprn.org/cprn-data-collection/) Copyright 2021 Cerebral Palsy Research Network. All rights reserved.
PrefixNamespace
xmlhttp://www.w3.org/XML/1998/namespace
xsdhttp://www.w3.org/2001/XMLSchema
vchttp://www.w3.org/2007/XMLSchema-versioning
pcorneturn:PCORnet
cprnhttp://www.cpresearch.net
<xsd:schema version="2.1" attributeFormDefault="unqualified" elementFormDefault="qualified" minVersion="1.1" targetNamespace="http://www.cpresearch.net">
   <xsd:import namespace="urn:PCORnet" schemaLocation="https://cprn.org/xsd-xml/PCORnet-v5dot1.xsd"/>
...
</xsd:schema>

Global Declarations

Element: CPRN-EHR

NameCPRN-EHR
TypeLocally-defined complex type
Nillableno
Abstractno
The CPRN-EHR element is the root element of an XML file to be submitted to CPRN. It identifies the site providing the data, the version of the data, when the data was generated and point in time the data is representative of.
<cprn:CPRN-EHR
 Version="xsd:string" [1]
 SiteId="xsd:string" [1]
 CreationDateTime="xsd:dateTime" [1]
 AsOfDateTime="xsd:dateTime" [1]
>
   <cprn:Providers> cprn:Providers </cprn:Providers> [0..1]
   <cprn:SubjectData> cprn:SubjectData </cprn:SubjectData> [1..*]
</cprn:CPRN-EHR>
<xsd:element name="CPRN-EHR">
   <xsd:complexType>
      <xsd:sequence>
         <xsd:element name="Providers" type="cprn:Providers" minOccurs="0" maxOccurs="1"/>
         <xsd:element name="SubjectData" type="cprn:SubjectData" minOccurs="1" maxOccurs="unbounded"/>
      </xsd:sequence>
      <xsd:attribute name="Version" type="xsd:string" use="required"/>
      <xsd:attribute name="SiteId" type="xsd:string" use="required"/>
      <xsd:attribute name="CreationDateTime" type="xsd:dateTime" use="required"/>
      <xsd:attribute name="AsOfDateTime" type="xsd:dateTime" use="required"/>
   </xsd:complexType>
</xsd:element>

Global Definitions

Complex Type: Conditions

Parent type:None
Sub-types:None
NameConditions
Abstractno
The Conditions element contains an array of Condition elements. This element is optional but when present must contain at least one PCORnet condition element.
<...>
   <cprn:Condition> pcornet:condition </cprn:Condition> [1..*]
</...>
<xsd:complexType name="Conditions">
   <xsd:sequence>
      <xsd:element name="Condition" type="pcornet:condition" maxOccurs="unbounded"/>
   </xsd:sequence>
</xsd:complexType>

Complex Type: Diagnoses

Parent type:None
Sub-types:None
NameDiagnoses
Abstractno
The Diagnoses element contains an array of Diagnosis elements. This element is optional but when present must contain at least one Diagnosis element.
<...>
   <cprn:Diagnosis> pcornet:diagnosis </cprn:Diagnosis> [1..*]
</...>
<xsd:complexType name="Diagnoses">
   <xsd:sequence>
      <xsd:element name="Diagnosis" type="pcornet:diagnosis" maxOccurs="unbounded"/>
   </xsd:sequence>
</xsd:complexType>

Complex Type: Dispensings

Parent type:None
Sub-types:None
NameDispensings
Abstractno
The Dispensings element contains an array of Dispensing elements. This element is optional but when present must contain at least one Dispensing element.
<...>
   <cprn:Dispensing> pcornet:dispensing </cprn:Dispensing> [1..*]
</...>
<xsd:complexType name="Dispensings">
   <xsd:sequence>
      <xsd:element name="Dispensing" type="pcornet:dispensing" maxOccurs="unbounded"/>
   </xsd:sequence>
</xsd:complexType>

Complex Type: Encounters

Parent type:None
Sub-types:None
NameEncounters
Abstractno
The Encounters element contains an array of Encounter elements. This element is optional but when present must contain at least one Encounter element.
<...>
   <cprn:Encounter> pcornet:encounter </cprn:Encounter> [1..*]
</...>
<xsd:complexType name="Encounters">
   <xsd:sequence>
      <xsd:element name="Encounter" type="pcornet:encounter" maxOccurs="unbounded"/>
   </xsd:sequence>
</xsd:complexType>

Complex Type: Immunizations

Parent type:None
Sub-types:None
NameImmunizations
Abstractno
The Immunizations element contains an array of Immunization elements. This element is optional but when present must contain at least one Immunization element.
<...>
   <cprn:Immunization> pcornet:immunization </cprn:Immunization> [1..*]
</...>
<xsd:complexType name="Immunizations">
   <xsd:sequence>
      <xsd:element name="Immunization" type="pcornet:immunization" maxOccurs="unbounded"/>
   </xsd:sequence>
</xsd:complexType>

Complex Type: Labs

Parent type:None
Sub-types:None
NameLabs
Abstractno
The Labs element contains an array of LabResult elements. This element is optional but when present must contain at least one LabResult element.
<...>
   <cprn:LabResult> pcornet:lab_result_cm </cprn:LabResult> [1..*]
</...>
<xsd:complexType name="Labs">
   <xsd:sequence>
      <xsd:element name="LabResult" type="pcornet:lab_result_cm" maxOccurs="unbounded"/>
   </xsd:sequence>
</xsd:complexType>

Complex Type: MedAdmins

Parent type:None
Sub-types:None
NameMedAdmins
Abstractno
The MedAdmins element contains an array of MedAdmin elements. This element is optional but when present must contain at least one MedAdmin element.
<...>
   <cprn:MedAdmin> pcornet:med_admin </cprn:MedAdmin> [1..*]
</...>
<xsd:complexType name="MedAdmins">
   <xsd:sequence>
      <xsd:element name="MedAdmin" type="pcornet:med_admin" maxOccurs="unbounded"/>
   </xsd:sequence>
</xsd:complexType>

Complex Type: ObservationsClinical

Parent type:None
Sub-types:None
NameObservationsClinical
Abstractno
The ObservationsClinical element contains an array of ObservationClinical elements. This element is optional but when present must contain at least one ObservationClinical element.
<...>
   <cprn:ObservationClinical> pcornet:obs_clin </cprn:ObservationClinical> [1..*]
</...>
<xsd:complexType name="ObservationsClinical">
   <xsd:sequence>
      <xsd:element name="ObservationClinical" type="pcornet:obs_clin" maxOccurs="unbounded"/>
   </xsd:sequence>
</xsd:complexType>

Complex Type: ObservationsGeneral

Parent type:None
Sub-types:None
NameObservationsGeneral
Abstractno
The ObservationsGeneral element contains an array of ObservationGeneral elements. This element is optional but when present must contain at least one ObservationGeneral element.
<...>
   <cprn:ObservationGeneral> pcornet:obs_gen </cprn:ObservationGeneral> [1..*]
</...>
<xsd:complexType name="ObservationsGeneral">
   <xsd:sequence>
      <xsd:element name="ObservationGeneral" type="pcornet:obs_gen" maxOccurs="unbounded"/>
   </xsd:sequence>
</xsd:complexType>

Complex Type: PcornetTrials

Parent type:None
Sub-types:None
NamePcornetTrials
Abstractno
This element is not currently used in CPRN data submissions.
<...>
   <cprn:PcornetTrial> pcornet:pcornet_trial </cprn:PcornetTrial> [1..*]
</...>
<xsd:complexType name="PcornetTrials">
   <xsd:sequence>
      <xsd:element name="PcornetTrial" type="pcornet:pcornet_trial" maxOccurs="unbounded"/>
   </xsd:sequence>
</xsd:complexType>

Complex Type: Prescribings

Parent type:None
Sub-types:None
NamePrescribings
Abstractno
The Prescibings element contains an array of Prescribing elements. This element is optional but when present must contain at least one Prescribing element.
<...>
   <cprn:Prescribing> pcornet:prescribing </cprn:Prescribing> [1..*]
</...>
<xsd:complexType name="Prescribings">
   <xsd:sequence>
      <xsd:element name="Prescribing" type="pcornet:prescribing" maxOccurs="unbounded"/>
   </xsd:sequence>
</xsd:complexType>

Complex Type: Procedures

Parent type:None
Sub-types:None
NameProcedures
Abstractno
The Procedures element contains an array of Procedure elements. This element is optional but when present must contain at least one Procedure element.
<...>
   <cprn:Procedure> pcornet:procedures </cprn:Procedure> [1..*]
</...>
<xsd:complexType name="Procedures">
   <xsd:sequence>
      <xsd:element name="Procedure" type="pcornet:procedures" maxOccurs="unbounded"/>
   </xsd:sequence>
</xsd:complexType>

Complex Type: ProCms

Parent type:None
Sub-types:None
NameProCms
Abstractno
This element is not currently used in CPRN data submissions.
<...>
   <cprn:ProCm> pcornet:pro_cm </cprn:ProCm> [1..*]
</...>
<xsd:complexType name="ProCms">
   <xsd:sequence>
      <xsd:element name="ProCm" type="pcornet:pro_cm" maxOccurs="unbounded"/>
   </xsd:sequence>
</xsd:complexType>

Complex Type: Providers

Parent type:None
Sub-types:None
NameProviders
Abstractno
The Providers element wraps an array of Provider elements. If providers are referenced within the XML document, in the form of a providerid element, then this element must be provided. There must be an entry for each provider referenced in the document. If providers are not referenced within the document this element may be omitted.
<...>
   <cprn:Provider> pcornet:provider </cprn:Provider> [1..*]
</...>
<xsd:complexType name="Providers">
   <xsd:sequence>
      <xsd:element name="Provider" type="pcornet:provider" maxOccurs="unbounded"/>
   </xsd:sequence>
</xsd:complexType>

Complex Type: StudyData

Parent type:None
Sub-types:None
NameStudyData
Abstractno
The StudyData element defines the study data for a participant. Each of the child elements is optional or may appear one time. When included elements must appear in the order shown in the table below.
<...>
   <cprn:Encounters> cprn:Encounters </cprn:Encounters> [0..1]
   <cprn:Diagnoses> cprn:Diagnoses </cprn:Diagnoses> [0..1]
   <cprn:Labs> cprn:Labs </cprn:Labs> [0..1]
   <cprn:Procedures> cprn:Procedures </cprn:Procedures> [0..1]
   <cprn:Prescribings> cprn:Prescribings </cprn:Prescribings> [0..1]
   <cprn:MedAdmins> cprn:MedAdmins </cprn:MedAdmins> [0..1]
   <cprn:Vitals> cprn:Vitals </cprn:Vitals> [0..1]
   <cprn:Conditions> cprn:Conditions </cprn:Conditions> [0..1]
   <cprn:ObservationsClinical> cprn:ObservationsClinical </cprn:ObservationsClinical> [0..1]
   <cprn:ObservationsGeneral> cprn:ObservationsGeneral </cprn:ObservationsGeneral> [0..1]
   <cprn:Immunizations> cprn:Immunizations </cprn:Immunizations> [0..1]
</...>
<xsd:complexType name="StudyData">
   <xsd:sequence>
      <xsd:element name="Encounters" type="cprn:Encounters" minOccurs="0"/>
      <xsd:element name="Diagnoses" type="cprn:Diagnoses" minOccurs="0"/>
      <xsd:element name="Labs" type="cprn:Labs" minOccurs="0"/>
      <xsd:element name="Procedures" type="cprn:Procedures" minOccurs="0"/>
      <xsd:element name="Prescribings" type="cprn:Prescribings" minOccurs="0"/>
      <xsd:element name="MedAdmins" type="cprn:MedAdmins" minOccurs="0"/>
      <xsd:element name="Vitals" type="cprn:Vitals" minOccurs="0"/>
      <xsd:element name="Conditions" type="cprn:Conditions" minOccurs="0"/>
      <xsd:element name="ObservationsClinical" type="cprn:ObservationsClinical" minOccurs="0"/>
      <xsd:element name="ObservationsGeneral" type="cprn:ObservationsGeneral" minOccurs="0"/>
      <xsd:element name="Immunizations" type="cprn:Immunizations" minOccurs="0"/>
   </xsd:sequence>
</xsd:complexType>

Complex Type: SubjectData

Parent type:None
Sub-types:None
NameSubjectData
Abstractno
The SubjectData element defines a study participant and their study data.
<...
 SubjectKey="xsd:string" [1]
>
   <cprn:Demographic> pcornet:demographic </cprn:Demographic> [1]
   <cprn:HashTokens> pcornet:hash_token </cprn:HashTokens> [0..1]
   <cprn:StudyData> cprn:StudyData </cprn:StudyData> [0..1]
</...>
<xsd:complexType name="SubjectData">
   <xsd:sequence>
      <xsd:element name="Demographic" type="pcornet:demographic"/>
      <xsd:element name="HashTokens" type="pcornet:hash_token" minOccurs="0" maxOccurs="1"/>
      <xsd:element name="StudyData" type="cprn:StudyData" minOccurs="0" maxOccurs="1"/>
   </xsd:sequence>
   <xsd:attribute name="SubjectKey" type="xsd:string" use="required"/>
</xsd:complexType>

Complex Type: Vitals

Parent type:None
Sub-types:None
NameVitals
Abstractno
The Vitals element contains an array of Vital elements. This element is optional but when present must contain at least one Vital element.
<...>
   <cprn:Vital> pcornet:vital </cprn:Vital> [1..*]
</...>
<xsd:complexType name="Vitals">
   <xsd:sequence>
      <xsd:element name="Vital" type="pcornet:vital" maxOccurs="unbounded"/>
   </xsd:sequence>
</xsd:complexType>

Glossary

Abstract (Applies to complex type definitions and element declarations). An abstract element or complex type cannot used to validate an element instance. If there is a reference to an abstract element, only element declarations that can substitute the abstract element can be used to validate the instance. For references to abstract type definitions, only derived types can be used.

All Model Group Child elements can be provided in any order in instances. See: http://www.w3.org/TR/xmlschema-1/#element-all.

Choice Model Group Only one from the list of child elements and model groups can be provided in instances. See: http://www.w3.org/TR/xmlschema-1/#element-choice.

Collapse Whitespace Policy Replace tab, line feed, and carriage return characters with space character (Unicode character 32). Then, collapse contiguous sequences of space characters into single space character, and remove leading and trailing space characters.

Disallowed Substitutions (Applies to element declarations). If substitution is specified, then substitution group members cannot be used in place of the given element declaration to validate element instances. If derivation methods, e.g. extension, restriction, are specified, then the given element declaration will not validate element instances that have types derived from the element declaration's type using the specified derivation methods. Normally, element instances can override their declaration's type by specifying an xsi:type attribute.

Key Constraint Like Uniqueness Constraint, but additionally requires that the specified value(s) must be provided. See: http://www.w3.org/TR/xmlschema-1/#cIdentity-constraint_Definitions.

Key Reference Constraint Ensures that the specified value(s) must match value(s) from a Key Constraint or Uniqueness Constraint. See: http://www.w3.org/TR/xmlschema-1/#cIdentity-constraint_Definitions.

Model Group Groups together element content, specifying the order in which the element content can occur and the number of times the group of element content may be repeated. See: http://www.w3.org/TR/xmlschema-1/#Model_Groups.

Nillable (Applies to element declarations). If an element declaration is nillable, instances can use the xsi:nil attribute. The xsi:nil attribute is the boolean attribute, nil, from the http://www.w3.org/2001/XMLSchema-instance namespace. If an element instance has an xsi:nil attribute set to true, it can be left empty, even though its element declaration may have required content.

Notation A notation is used to identify the format of a piece of data. Values of elements and attributes that are of type, NOTATION, must come from the names of declared notations. See: http://www.w3.org/TR/xmlschema-1/#cNotation_Declarations.

Preserve Whitespace Policy Preserve whitespaces exactly as they appear in instances.

Prohibited Derivations (Applies to type definitions). Derivation methods that cannot be used to create sub-types from a given type definition.

Prohibited Substitutions (Applies to complex type definitions). Prevents sub-types that have been derived using the specified derivation methods from validating element instances in place of the given type definition.

Replace Whitespace Policy Replace tab, line feed, and carriage return characters with space character (Unicode character 32).

Sequence Model Group Child elements and model groups must be provided in the specified order in instances. See: http://www.w3.org/TR/xmlschema-1/#element-sequence.

Substitution Group Elements that are members of a substitution group can be used wherever the head element of the substitution group is referenced.

Substitution Group Exclusions (Applies to element declarations). Prohibits element declarations from nominating themselves as being able to substitute a given element declaration, if they have types that are derived from the original element's type using the specified derivation methods.

Target Namespace The target namespace identifies the namespace that components in this schema belongs to. If no target namespace is provided, then the schema components do not belong to any namespace.

Uniqueness Constraint Ensures uniqueness of an element/attribute value, or a combination of values, within a specified scope. See: http://www.w3.org/TR/xmlschema-1/#cIdentity-constraint_Definitions.