Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: updated decimal, float, and double

...

Info

All XML attribute values and some element bodies are text strings. These strings are defined by data format. Each data format specifies the allowable form of the string, the corresponding XML Schema datatype, and the intended use of the value. The set of ODM data formats follows:


Format NameSchema DatatypeAllowed String Pattern
integerxs:integer-?digit+
positiveIntegerxs:positiveInteger+?digit+ (and representing an integer number > 0)
nonNegativeIntegerxs:nonNegativeInteger+?digit+ (and representing an integer number >= 0)
float
decimalxs:decimal-?digit+(.digit+)?
floatxs:float[\+\-]?\digit*\.?\digit+(?:[Ee][\+\-]?\digit+)?
doublexs:double[\+\-]?\digit*\.?\digit+(?:[Ee][\+\-]?\digit+)?
datexs:dateYYYY-MM-DD
timexs:timehh:mm:ss(.n+)? (((+|-)hh:mm)|Z)?
datetimexs:dateTimeYYYY-MM-DDThh:mm:ss(.n+)?(((+|-)hh:mm)|Z)?
textxs:stringany sequence of characters
oidxs:stringany sequence of characters (minLength="1")
oidrefxs:stringany sequence of characters (minLength="1")
IDxs:IDany sequence of characters (minLength="1")
IDREFxs:IDREFany sequence of characters (minLength="1")
subjectKeyxs:stringany sequence of characters (minLength="1")
repeatKeyxs:stringany sequence of characters (minLength="1")
namexs:stringany sequence of characters (minLength="1")
sasNamexs:string( letter | _ )( letter | digit | _ )* (maxLength="8")
sasFormatxs:string( letter | _ | $ )( letter | digit | _ | . )* (maxLength="8")
fileNamexs:anyURIany sequence of characters
languageTagxs:languageLL (-CC)* (see below)
stringxs:stringSemantically equivalent to text but directly supported as XML Schema datatype
booleanxs:boolean(true | false | 1 | 0)
doublexs:string(((\+|-)?[0-9]+(\.[0-9]+)?((D|d|E|e)(\+|-)[0-9]+)?)|(-?INF)|(NaN))
hexBinaryxs:hexBinaryhex-encoded binary stream data
base64Binaryxs:base64Binarybinary stream encoded using Base64 Alphabet
hexFloatxs:hexBinaryup to 16 characters
base64Floatxs:base64Binaryup to 12 characters
partialDatexs:date[YYYY[-MM[-DD ]]]
partialTimexs:time[hh[:mm[:ss(.n+)? (((+|-)hh:mm)|Z)?]]]
partialDatetimexs:dateTime[YYYY[-MM[-DD[T hh[:mm[:ss(.n+)? ((+|-)hh:mm)?]]]]]]
intervalDatetimexs:stringpartialDatetime/partialDatetime)|(durationDatetime/partialDatetime)|(partialDatetime/durationDatetime)
durationDatetimexs:duration(((+|-)?P((((n(n+)?)Y)?((nn+)?)M)?((nn+)?)D)?)(T(((n(n+)?)H)?((n(n+)?)M)?((n(n+)?)((\.n+)?)S)?)?)?|(((n(n+)?)W))))
incompleteDatetimexs:string[YYYY|-]-[MM |-]-[DD|-]]]T[hh|-]:[mm|-]:[ss.s|-][?(+|-)nn:nn|Z]
incompleteDatexs:string[YYYY|-]-[MM |-]-[DD|-]
incompleteTimexs:stringT[hh|-]:[mm|-]:[ss.s|-][?(+|-)nn:nn|Z]
URIxs:anyURI


Info

Numbers are represented in base 10. Floats are allowed to have fractional parts.

Note: Certain integer attributes (KeySequence, OrderNumber, and SeqNum) are used to define an order among related entities. For these attributes, we recommend using consecutive integer values starting at 1.

...

Info

Example: "fr-CA" denotes the French language, Canadian variant. See TranslatedText (archive) for a discussion of how languageTags are used.

In general for data formats that allow NULLs, you should use an empty string (e.g., attribute-name="") to represent a NULL attribute value. To represent a NULL for data transmitted in an element body, send the element as empty (e.g. <element-name/>). There is a special IsNull indicator for clinical data, to differentiate between the case where there is no known value, and the case where you want to replace a value with NULL. See the IsNull attribute of the ItemData element.

See the ODM Foundation Schema for definitions of the enumeration types and the ODM Example XML file

Jira
serverIssue Tracker (JIRA)
serverId85506ce4-3cb3-3d91-85ee-f633aaaf4a45
keyODM2DEV-31
for the further examples of legal and illegal values for each of the ODM clinical data formats.

...