In addition to entering data directly into electronic Case Report Forms (eCRFs), you can also import data into eCRFs using CDISC ODM XML format. 

Prerequisite for Data Import:

You must have a Participant with a Form in an Event that is available for data entry. The Form can be empty, partially filled, or complete. 

If you import data into a complete Form, the standard system-generated reason for change, Update via Import, is applied to each change, and any pre-existing values that have been changed are overwritten. 

Note: If the Form was previously signed, importing data removes the signature.

To Import Data into a Form:

1. Click Tasks in the header bar of Runtime.

2. Select Import Data.

3. Click the Choose File button, and select your import XML data file.

4. Click the Submit button.

Note: You can download a template import XML file from the Import Data screen.

 

Click Tasks in the header bar and select Bulk Actions Log to check the status of the import process. 

 

XML Imports

XML file is a combination of CDISC ODM v1.3.2 and some OpenClinica specific tags.

Functionality of the import is limited to certain actions and activities. Here are some general rules when building the import XML file: Here’s a template file to help you.

  • The Import file must contain the following namespaces:
    • <?xml version="1.0" encoding="UTF-8"?>
      <ODM xmlns="http://www.cdisc.org/ns/odm/v1.3" xmlns:OpenClinica="http://www.openclinica.org/ns/odm_ext_v130/v3.1" ODMVersion="1.3">
    • In addition to the above, FileOID, FileType, Description, and CreationDateTime information can also be provided within the <ODM> tag. This information is not used by the OpenClinica system. However, you may use these properties for internal documentation if you’d like.
  • The Import file should only contain one <ClinicalData> tag pair. Though the Import file will not generate an error if it contains multiple <ClinicalData> tag pairs, the system only processes the data in the first <ClinicalData> tag pair and ignores the others. 
  • The Import file can contain data for multiple subjects as long as they are all between the opening and closing tags of the first <ClinicalData> tag. To allow for multiple subjects, copy everything between the opening and closing tags of <SubjectData>, including the tags, and the paste it after the closing tag of </SubjectData>. Then update the OIDs and data in the new section.
  • The Import file can contain multiple <StudyEventData>, <FormData>, <ItemGroupData> and <ItemData> tags as long as their hierarchy is maintained. Copy and paste these sections as needed to import multiple events, forms, item groups, and items.
  • When a repeating, visit-based event definition contains multiple forms, then all the forms of that event repeat/ordinal can be combined within the same <StudyEventData> tag with one repeat/ordinal value.
    • For every new study event repeat/ordinal for a participant, the <StudyEventData> tag construct needs to be repeated within that participant’s <SubjectData> tags.
    • When a repeat ordinal is not provided for a repeating study event, then the system automatically generates a new repeat/ordinal of that event for that participant.
  • When a common event definition contains multiple forms, then every form should be provided with its own <StudyEventData> tag and a new event/repeat ordinal. When an ordinal is not provided then system creates a new repeat for the given event.
  • Import is not allowed into a form when any of the following conditions are met:
    • Study / Site is in Design, Frozen, or Locked status
    • Study Event (or repeat thereof) is in Locked status, has been removed for the participant, or is no longer available in the study
    • Form is in Completed status, has been removed for the participant, or is no longer available in the study

Please refer to the following links for further details about each data tag in the CIDSC ODM XML:

  1. SubjectData tag
  2. StudyEventData tag
  3. FormData tag
  4. ItemGroupData tag
  5. ItemData

Below is a sample CDISC ODM XML file structure for reference. To use this as a template, copy the text below and paste it into an XML file. Then update the OIDs as needed. Or, Click here to download the file.

<?xml version="1.0" encoding="UTF-8"?>
<ODM xmlns="http://www.cdisc.org/ns/odm/v1.3" xmlns:OpenClinica="http://www.openclinica.org/ns/odm_ext_v130/v3.1" ODMVersion="1.3" FileOID="1D20080412202420" FileType="Snapshot" Description="Demographics Import" CreationDateTime="2008-04-12T20:24:20" >

  <!-- StudyOID represents either the Study OID (if a study-level user is importing data) or the Site OID (if a site-level user is importing data). -->
  <ClinicalData StudyOID="S_OID" MetaDataVersionOID="null">
    <!--SubjectKey (optional) is the Participant OID. If not used, remove the entire text 'SubjectKey="SS_OID"'. 
        OpenClinica:StudySubjectID (required) represents the Participant ID. -->
    <SubjectData SubjectKey="SS_OID" OpenClinica:StudySubjectID="PID-001">
	<!--StudyEventOID (required): The OID for the event into which you are importing data.
           StudyEventRepeatKey (optional): The ordinal for a repeating event. 
	   If removed, a new study event ordinal is automatically generated.
	   For a visit-based event OpenClinica:StartDate is required.
	   If the StudyEventRepeatKey value is provided and the specified repeat is already in the database, 
then the system updates the form data for that study event repeat on import. OpenClinica:EndDate (optional): If the event has a scheduled end date, you can provide that here. Otherwise, delete it or leave it same as start date.--> <StudyEventData StudyEventOID="SE_OID" OpenClinica:StartDate="2017-09-29" OpenClinica:EndDate="2017-09-29" StudyEventRepeatKey="1"> <!--FormOID (required): The OID for the form into which you are importing data. OpenClinica:FormLayoutOID (optional): If no value is provided then the system assigns the default form version to the participant event form. OpenClinica:Status (optional): Possible values for OpenClinica:Status are: 'initial data entry' or 'complete'.
If no value is provided, then the system assigns the status 'initial data entry' to the participant event form on import. --> <FormData FormOID="F_OID" OpenClinica:FormLayoutOID="1.1" OpenClinica:Status="initial data entry"> <!--ItemGroupOID (required): The OID for the item group into which you are importing data. ItemGroupRepeatKey (optional): If not provided, a new repeat key is auto-generated on import.
If a value is provided and the provided repeat key already exists in the database,
then the associated item data is updated in that item group repeat upon import. --> <ItemGroupData ItemGroupOID="IG_OID" ItemGroupRepeatKey="1"> <!--ItemOID and Value (required): The OID of the item into which you are importing data and the data value to be imported into that item.
Any issues with the value of the item will be reported in the log file with an appropriate errorCode. --> <ItemData ItemOID="I_OID" Value="2017-09-13"/> <ItemData ItemOID="I_OID" Value="1"/> <ItemData ItemOID="I_OID" Value="Headache"/> </ItemGroupData> </FormData> </StudyEventData> <!--To import data for more than one Study event, repeat the StudyEventData tag and everything within the opening and closing tags. For a visit-based event with multiple forms, all forms belonging to one repeat of that event should be combined under the same StudyEventData tag. For commom events, each FORM should be provided with a SEPARATE pair of StudyEventData tags.--> </SubjectData> <!-- To import data for more than one Subject, copy and paste the opening and closing SubjectData tags, and everything between those tags. Then update OIDs and values as needed.--> </ClinicalData>

</ODM>

Note:

The XML file can also be generated using an existing Participant’s casebook. Say, data for one of the participants has already been captured into a form and now data needs to be entered into another participants. In this case, user can follow the steps below to quickly generate the XML file to import the clinical data into other participants:

  • Go the 360 page of participant for who data has been captured
  • Scroll to the bottom and Click on the Download data link
  • Select the CDISC XML format and uncheck all the check boxes
  • Click Run now
  • Casebook in XML format for that participant will generate
  • Save this casebook as an XML file on your local directory
  • Open the file in a Notepad application
  • Change the participant ID and OID values along with the values of the items as per the new participant for who data needs to be entered
    • If data for multiple participants need to be captured, then copy and paste everything between opening and closing brackets of <SubjectData> tag and edit the participant ID, OID and item values as per the other participant.
  • Save the file and call Import API using this file.