XML Tutorial
This page provides a brief introduction to XML, the electronic file format used in eStability’s electronic data submission. Of course, with ScienTek Software’s eStability Suite, the creation and management of files are handled for you. You can skip this page unless you are interested in learning more about the under pinnings of eStability. Click here to see what things look like in the ScienTek eViewer.
XML stands for eXtensible Markup Language. In a nutshell, an XML file stores data. For example, the following is an XML file that stores a catalog of books:
As you can see, the contents are immediately clear about its intention.
Here are some definitions:
• An element name must be closed, e.g. the element <author> must be closed by </author>.
eStability XML Example
The following is an example how eStability stores the container and closure information. This is an excerpt from a much larger file that represents a stability study.
Here are some definitions:
- Element - <catalog>, <book>, <author>, etc. are called elements. The <book> element contains children elements of <author>, <title>, etc.
• An element name must be closed, e.g. the element <author> must be closed by </author>.
- Attribute - The <book> element contains an attribute of id; e.g. <book id="bk501">
eStability XML Example
The following is an example how eStability stores the container and closure information. This is an excerpt from a much larger file that represents a stability study.
Schema
A schema is a set of rules or grammar for the XML file. Each XML file must have the corresponding schema. eStability uses the HL7 schema. Here is the HL7 schema for the <container> element in the previous section:
A schema is a set of rules or grammar for the XML file. Each XML file must have the corresponding schema. eStability uses the HL7 schema. Here is the HL7 schema for the <container> element in the previous section:
This schema tells us:
- element names - A container must have the following elements: <code>, <desc>, <lotNumberText>, <capacityQuantity>, and <capTypeCode>.
- sequence - The elements of <code>, <desc>, <lotNumberText>, <capacityQuantity>, and <capTypeCode> must appear in the sequence indicated.
- type - Each element has its own distinct data type. For example, the <lotNumberText> has ST data type indicating the lot number is a character string. The <capacityQuantity> has a PQ data type indicating that it is a physical quantity.
- occurrence - The code element is optional because the value of the minOccurs attribute in its declaration is 0. In general, an element is required to appear when the value of minOccurs is 1 or more. The maximum number of times an element may appear is determined by the value of a maxOccurs attribute in its declaration. This value may be a positive integer such as 5, or if maxOccurs is not specified, this indicates that there is no maximum number of occurrences. The default value for both the minOccurs and the maxOccurs attributes is 1 (if either is not specified).