This document describes the properties that can be defined in a Tamino schema. It covers the following topics:
Note:
When not indicated otherwise, the properties are available in all
views.
A schema has only logical properties.
Logical constructs are described in detail in the XML Schema Part 0: Primer on the W3C site http://www.w3.org/TR/xmlschema-0/.
Schema Editor Property | Schema Language Syntax | Short Description | |
---|---|---|---|
Schema name | <tsd:schemaInfo name =
"name"> |
Name of the schema. |
|
Collection name | <tsd:collection name =
"name"> |
Name of the Tamino collection to which the schema is to belong. If the collection does not exist, it is created. |
|
Namespaces | <xs:schema
xmlns:prefix1 =
"namespace1"
xmlns:prefix2 =
"namespace2" targetNamespace =
"namespace2"> |
The Tamino Schema Editor provides a property editor that allows you to specify namespace declarations, including the target namespace declaration. See Namespaces. The Tamino Schema Editor moves all namespace declarations to the schema node and manages them there. For namespaces, see W3C's Namespaces in XML recommendation at http://www.w3.org/TR/REC-xml-names/. For target namespace, see XML Schema Part 0: Primer, section 3.1. |
|
Target namespace | Displays the target namespace (read only). This can be changed between the defined namespaces. | ||
Attribute form default | <xs:schema attributeFormDefault =
"unqualified|qualified"...> |
Specifies whether attributes in instances of the schema must be qualified with a namespace prefix. Default is "unqualified". |
|
Element form default | <xs:schema elementFormDefault =
"unqualified|qualified"...> |
Specifies whether elements in instances of the schema must be qualified with a namespace prefix. Default is "unqualified". |
|
Final default attribute | <xs:schema finalDefault="#all | List of
(extension | restriction)">
|
Determines the default behavior in the case of derivation. |
|
XML Schema version | <xs:schema version =
"version"> |
Version of the schema. |
|
Language identification | <xs:schema xml:lang =
"en"> |
Language identification. See W3C's XML recommendation at http://www.w3.org/TR/REC-xml/#sec-lang-tag. |
|
ID | id="id" |
Unique identifier for the schema element within the schema XML document. See W3C's XML recommendation at http://www.w3.org/TR/REC-xml/#id. |
|
Tamino schema information |
Open the group tree to display the following properties. |
||
Version | <tsd:version>version</tsd:version> |
Version of the schema. Value provided by the Tamino Server (read-only). |
|
Created | <tsd:created>created</tsd:created> |
Creation date of the schema. Value provided by the Tamino Server (read-only). |
|
Modified | <tsd:modified>modified</tsd:modified> |
Date the schema was last saved. Value provided by the Tamino Server (read-only). |
|
Server | <tsd:server>server</tsd:server> |
Version of the Tamino Server. Value provided by the Tamino Server (read-only). |
The following example shows the generated code for a schema named "patientschema" in the Tamino collection "hospital". Element and attribute form are unqualified.
<?xml version = "1.0" encoding = "UTF-8"?> <xs:schema xmlns:xs = "http://www.w3.org/2001/XMLSchema" xmlns:tsd = "http://namespaces.softwareag.com/tamino/TaminoSchemaDefinition"> <xs:annotation> <xs:documentation>Schema modelling a hospital patient's record.</xs:documentation> <xs:appinfo> <tsd:schemaInfo name = "patientschema"> <tsd:collection name = "hospital"> .... ....
A doctype has logical and physical properties.
Schema Editor Property | Schema Language Syntax | Short Description |
---|---|---|
Doctype name | <tsd:doctype name =
"name"> |
Name of the Tamino doctype. This name must be the same as the name of the root element declaration. |
Namespaces | <xs:doctype xmlns:prefix1 =
"namespace1"
xmlns:prefix2 =
"namespace2"> |
This namespace declaration serves as hint for namespace cleaning and Tamino X-Query processing. Tamino X-Query processing requires namespace URIs. Since the X-Query language allows only prefixes to be used, the mapping between the prefix and the URI for a doctype is done by these namespace declarations. For namespaces, see W3C's Namespaces in XML recommendation at http://www.w3.org/TR/REC-xml-names/. For query processing, see Namespace Handling for Specific XMachine Requests in the XML Namespaces in Tamino section of the Tamino XML Server documentation. |
The physical properties for a Tamino doctype depend on the storage type that has been specified for the doctype.
The following table lists all properties in alphabetical order that are available for the different storage types (XML, Non-XML and shadow XML).
Schema Editor Property | Schema Language Syntax | Storage Type | Short Description |
---|---|---|---|
Compress | <tsd:compress>always |
XML |
Specifies data compression on data storage.
|
Computed Indexes | <tsd:computedIndex></tsd:computedIndex>
|
XML and Shadow XML |
Specifies the use of one or more computed indexes, and allows you to define the XQuery function to be used for each computed index. You can select the property editor for this field by choosing the button. In the property editor, supply values for the required collation properties. Also in the property editor, in the Name column, select the line containing "New_Computed_Index", and choose the button in the corresponding Computed Index Function column. The resulting dialog allows you to select a stored XQuery function from an XQuery module in the Tamino database. If you wish to define more than one computed index, use the icon to create a new entry in the list of computed indexes. The computed indexes are displayed in the list of physical
properties in the form |
Content | <tsd:content>closed |
XML |
Default is "closed", meaning instances containing instances not defined in the schema are rejected. The value "open" means instances are
stored even if they contain structures not defined in the schema. You should
coordinate this value with |
Delete access | <tsd:delete> </tsd:delete> |
All storage types |
Default is "true", meaning instances may be deleted from the Tamino XML data store. |
ino:id re-usage | <tsd:systemGeneratedIdentity reuse =
"booleanValue">
</tsd:systemGeneratedIdentity> |
XML |
Specifies whether an ino:id is to be reused if an instance is removed from the data store or not. Default is "true". See the description of the element |
Insert access | <tsd:insert> </tsd:insert> |
All storage types |
Default is "true", meaning instances may be inserted into the Tamino XML data store. |
No conversion | <tsd:nonXML>
<tsd:noConversion>
</tsd:noConversion>
</tsd:nonXML> |
Non-XML |
Possible values are "true" and "false". Default is "true", meaning that the doctype node is of type non-XML. Text indexing is not possible for data stored into doctypes with the noConversion flag set. |
Pure X-Node mapping | <tsd:map><tsd:pure> |
XML |
The default is "false", meaning that this property is not active. This property is only applicable to Tamino schemas that have no other function than expressing a mapping to one Adabas file. If this property is set to "true", Tamino stores all data except the schema in the Adabas file. If elements of your schema are mapped to Adabas PE groups or MU
fields, it is recommended that you set the property |
Read access | <tsd:read> </tsd:read> |
All storage types |
Default is "true", meaning instances may be read from the Tamino XML data store. |
Structure index | <tsd:structureIndex>value |
XML |
Specifies that all nodes not declared by the schema will be registered in the repository. Possible values:
For details on structure indexing, see Indexing in the Advanced Concepts section of the Tamino XML Server documentation. |
Update access | <tsd:update> </tsd:update> |
All storage types |
Default is "true", meaning existing instances may be updated in the Tamino XML data store. |
The Tamino doctype properties in the examples below define a Tamino doctype "patient".
In the first example, the content of the doctype is defined as "closed", meaning only those instances will be stored which contain structures defined in the schema. Instances may be read, but not inserted, updated or deleted from the Tamino store:
.... <tsd:doctype name = "patient"> <tsd:logical> <tsd:accessOptions> <tsd:read></tsd:read> </tsd:accessOptions> </tsd:logical> </tsd:doctype> ....
In the second example, all instances will be stored, even if they contain structures not defined in the schema. Instances may be read, inserted, updated or deleted from the Tamino store:
.... <tsd:doctype name = "patient"> <tsd:logical> <tsd:content>open</tsd:content> <tsd:accessOptions> <tsd:read></tsd:read> <tsd:insert></tsd:insert> <tsd:delete></tsd:delete> <tsd:update></tsd:update> </tsd:accessOptions> </tsd:logical> </tsd:doctype> ....
The Tamino Schema Editor always shows the logical properties that are relevant to the element that is currently selected in the schema tree.
The following table lists all logical properties in alphabetical order. Not all properties may be available for the currently selected element.
For detailed information and examples, see the following W3C recommendation:
XML Schema Part 0: Primer at http://www.w3.org/TR/xmlschema-0/.
XML Schema Part 1: Structures at http://www.w3.org/TR/xmlschema-1/.
XML Schema Part 2: Datatypes at http://www.w3.org/TR/xmlschema-2/.
Schema Property | Short Description | |||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Abstract |
For elements and types. When an element or type is declared to be abstract, it cannot be used in an instance document. See XML Schema Part 0: Primer, section 4.7. |
|||||||||||||
Block |
For complex types and elements. Controls which derivations and substitution groups may be used in instance documents. See XML Schema Part 0: Primer, section 4.8. |
|||||||||||||
Collation |
To enter a collation, change the value of the logical property
If the value of If the value of For information on the ICU Collation Service, see http://www.icu-project.org/. Open the group tree to display the following properties. |
|||||||||||||
Collation language |
Only available if Specifies locale by ISO-3166 language code and country for collating purposes. For example, "DE" for German or "DE-AT" for Austrian German. There is no default, meaning collating keys are language neutral. This should provide good results for most languages. |
|||||||||||||
Collation strength |
|
|||||||||||||
Collation case first |
Only available if With "upperfirst" (default), words starting with uppercase will be sorted before words starting with lowercase. A value of "lowerFirst" will reverse this behavior. |
|||||||||||||
Collation alternate |
Only available if The value "shifted" sorts words containing punctuation marks together (e.g. "bi-weekly" and "biweekly"), that is, punctuation is ignored for levels 1 through 3. The value "non-ignorable" (default) will distinguish these words and sort them separately, that is, punctuation marks will be accounted for. |
|||||||||||||
Collation case level |
Only available if The value "true" makes a separate collation level for case differences, positioned between level 2 (secondary) and level 3 (tertiary). This is used primarily in Japanese to make the difference between small and large Kana more important than the other tertiary differences. The default is "false". |
|||||||||||||
Collation french |
Only available if The value "true" will produce French
accent sorting. The default is "false", but the
function is switched on if |
|||||||||||||
Collation normalization |
Only available if The value "true" produces results as if text were normalized. The default is "false" (no normalization) for most languages. |
|||||||||||||
context |
For element info and attribute info. Specifies the element or attribute for which the physical properties are defined. The element or attribute is addressed by a path. For information on the path syntax, see Advanced Physical Properties. |
|||||||||||||
Data type |
The base type of the declared type, element or attribute. See Schema Tree Items Explained. |
|||||||||||||
Default value |
For attribute declarations, specifies the value used if the
attribute is absent from an instance (the For element declarations, specifies the element content if the element occurs in the instance but is empty. Element instance content overrides the default value. The properties |
|||||||||||||
Default function |
For elements and attributes. The name of the server extension function that calculates the default value. The required server extension can be selected from a dialog box. See Server Extensions for further information. |
|||||||||||||
Derivation method |
For complex types and elements. Selects the derivation method to be used. See Schema Tree Items Explained. |
|||||||||||||
Documentation text |
The text of the documentation node. The Tamino Schema Editor provides a property editor for entering the text. See Documenting a Schema. |
|||||||||||||
Facets |
Open the group tree to display the following properties. When the Fixed check box is marked for one of the facets, the value for this facet cannot be derived any further. |
|||||||||||||
Length |
Specifies the string length. See XML Schema Part 2: Datatypes, section 4.3.1. |
|||||||||||||
Minimum length |
Specifies the minimal string length. See XML Schema Part 2: Datatypes, section 4.3.2. |
|||||||||||||
Maximum length |
Specifies the maximal string length. See XML Schema Part 2: Datatypes, section 4.3.3. |
|||||||||||||
Total digits |
Specifies the maximum number of digits allowed in an element marked
as datatype "decimal". See also the property
|
|||||||||||||
Fraction digits |
Specifies the maximum number of digits in the fractional part of
elements marked as datatype "decimal". If
|
|||||||||||||
Min inclusive |
Constrains the value space to values with a specific inclusive lower bound. See XML Schema Part 2: Datatypes, section 4.3.10. |
|||||||||||||
Max inclusive |
Constrains the value space to values with a specific inclusive upper bound. See XML Schema Part 2: Datatypes, section 4.3.7. |
|||||||||||||
Min exclusive |
Constrains the value space to values with a specific exclusive lower bound. See XML Schema Part 2: Datatypes, section 4.3.9. |
|||||||||||||
Max exclusive |
Constrains the value space to values with a specific exclusive upper bound. See XML Schema Part 2: Datatypes, section 4.3.8. |
|||||||||||||
Regular expression pattern |
Contains a regular expression that constrains the value. See XML Schema Part 2: Datatypes, section 4.3.4. |
|||||||||||||
Enumeration |
Specifies a particular value that the element may contain. Multiple enumeration elements thus specify/restrict the possible values of an element. The Tamino Schema Editor provides a property editor that allows you to specify new values and/or delete existing ones. See Using the Property Editor. |
|||||||||||||
Whitespace |
Specifies how whitespace is to be treated. See XML Schema Part 2: Datatypes, section 4.3.6. |
|||||||||||||
Field xpaths |
For identity constraints. Tsd unique: specifies the xpath from the doctype root element to the field or fields that are to be identical. For more information on defining unique keys, see Physical Schema for Elements and Attributes in the Tamino XML Schema User Guide (located in the Tamino XML Server documentation). Unique: specifies the xpath from the element to the field or fields that are to be identical. See XML Schema Part 0: Primer, section 5.1. |
|||||||||||||
Final |
For types and elements. Controls whether further derivation is permitted. See XML Schema Part 0: Primer, section 4.8. |
|||||||||||||
Fixed value |
For attributes and elements.
The properties |
|||||||||||||
foreign appinfo |
Contains all application information that is not from Tamino. This information may be edited as mixed content text. |
|||||||||||||
Form |
Specifies for the element or attribute declaration whether instance element names must be qualified with the namespace prefix. See XML Schema Part 0: Primer, section 3.1. |
|||||||||||||
ID |
Unique identifier for the schema element within the schema XML document. See W3C's XML recommendation at http://www.w3.org/TR/REC-xml/#id. |
|||||||||||||
Item type |
For simple types, elements and attributes. Defines the item type of a list. See Schema Tree Items Explained. |
|||||||||||||
Language identification |
Language identification. See W3C's XML recommendation at http://www.w3.org/TR/REC-xml/#sec-lang-tag. |
|||||||||||||
Maximum occurrence |
Indicates the maximum number of occurrences of the node allowed in an instance. For possible values, see XML Schema Part 0: Primer, section 2.2.1. See also Specifying the Occurrence Constraints. |
|||||||||||||
Member types |
For simple types, elements and attributes. Defines types that are part of a union. See Schema Tree Items Explained. |
|||||||||||||
Minimum occurrence |
Indicates the minimum number of occurrences of the node allowed in an instance. For possible values, see XML Schema Part 0: Primer, section 2.2.1. See also Specifying the Occurrence Constraints. |
|||||||||||||
Mixed content |
For complex elements only: mixed content is allowed. See XML Schema Part 0: Primer, section 2.5.2. |
|||||||||||||
Name |
Name of the declared node. |
|||||||||||||
Namespace |
For |
|||||||||||||
Nillable |
For types and elements. Defines whether an empty (instance) element
may be flagged by the |
|||||||||||||
processContents |
For |
|||||||||||||
Public notation identifier |
The public identifier of the notation declaration, a URI reference. See XML Schema Part 1: Structures, section 3.12. |
|||||||||||||
Reference |
For element, attribute, group, attribute group references. Contains the name of the referenced item. |
|||||||||||||
Refer |
For key references. References a key by its name. See XML Schema Part 0: Primer, section 5.2. |
|||||||||||||
Schema location |
For import, include and redefine declarations. The location of the referenced schema. It can either be stored in a Tamino database or in the file system. You can open the referenced schema in a new instance of the Tamino Schema Editor. See also:
Opening a
Referenced Schema in a New Window |
|||||||||||||
selector-xpath |
For identity constraints. Selects the identical elements relative to the constraint definition by xpath. See XML Schema Part 0: Primer, section 5.1. |
|||||||||||||
source |
For documentation and appinfo. Describes the source of its content as an URI. See XML Schema Part 1: Structures, section 3.13.2. |
|||||||||||||
Substitution group |
For elements. Defines which elements can be substituted for other elements. See XML Schema Part 0: Primer, section 4.6. |
|||||||||||||
System |
The system identifier of the notation declaration. See XML Schema Part 1: Structures, section 3.12. |
|||||||||||||
Trigger |
An action trigger is a server extension that executes an action when an event in the Tamino Server occurs. This action is executed in addition to the normal processing on the server. See X-Tension: Tamino Server Extensions in the Tamino XML Server documentation for further information. There are three types of triggers available (On Delete, On Insert, and On Update). There can be multiple triggers of same trigger type. The required server extension can be selected from a dialog box. See Server Extensions for further information. The values for the additional parameters of the selected trigger function can be specified the triggers dialog. |
|||||||||||||
Use |
For attribute declarations. Specifies whether the attribute is required, optional or prohibited. See XML Schema Part 0: Primer, section 2.2.1. See also Declaring an Element as Optional, Required or Prohibited. |
|||||||||||||
Variety |
For simple types and elements. Selects the variety to be used. See Schema Tree Items Explained. |
Different storage types are available:
Note:
A doctype uses other storage types. See
Tamino Doctype
Properties.
Elements and attributes of XML documents can be stored in Tamino's native XML store by specifying "Native" as the storage type.
See also Tamino-specific Extensions to Physical Schema in the Tamino XML Schema User Guide (located in the Tamino XML Server documentation).
Note:
The properties for the references are described below under
Object References.
The properties for the indices and for referencing are available from two different tabs: Index and Reference.
Note:
The properties for the references are described below under
Object References.
Different types of indices can be defined: standard, text and reference
index definitions. Different index technologies can be used: simple index,
reference index, multi-path index and compound index. The index technology is
defined by selecting a specific type of index and then specifying the required
properties: Refers
,
Multipath
and/or Field
xpaths
. Each node can have several standard and text indices.
However, it can have only one reference index.
For more details, refer to Indexing XML Data for Native Storage in the Tamino XML Schema User Guide (located in the Tamino XML Server documentation.
The following buttons are provided:
Add a new index. | |
Delete the selected index. |
For each index, select one of the following values:
Type of Index | Short Description | ||||||||
---|---|---|---|---|---|---|---|---|---|
text |
|
||||||||
standard |
|
||||||||
reference |
|
Elements mapped to object references are used to join information retrieved from different Tamino doctypes. Object references can also be stored in Tamino's native XML store by specifying "Native" as the storage type.
Schema Editor Property | Short Description |
---|---|
Collection reference |
Name of the Tamino collection containing the doctype to be referenced. The default is the current collection. |
Dereference |
Specifies whether the contents of the referenced node must always be included in the current node ("true") or not ("false"). The default is "false". This option is not available on attributes, since they have no element content. |
Node reference |
Path to the node that is referenced. |
Node reference operator |
Specifies the operator used when referencing another object. Possible operators are:
=, |
The following illustrates the native storage of a node "firstname" with a full-text index:
<xs:element name = "firstname" type = "xs:string"> <xs:annotation> <xs:appinfo> <tsd:elementInfo> <tsd:physical> <tsd:native> <tsd:index> <tsd:text></tsd:text> </tsd:index> </tsd:native> </tsd:physical> </tsd:elementInfo> </xs:appinfo> </xs:annotation> </xs:element>
Elements and attributes of XML documents can be mapped to an Adabas file in the following way:
Schema Construct | Possible Storage Type | Meaning |
---|---|---|
Complex element declaration | Map SubTreeAdabas or Map SubTreeAdabasPE | Adabas file (subtree) or Adabas periodic group. |
Simple element declaration | Map NodeAdabasField | Adabas elementary or multiple value field. |
Element with attributes declaration | Map NodeAdabasField | Adabas elementary or multiple value field. |
Attribute declaration | Map NodeAdabasField | Adabas elementary or multiple value field. |
Schema Editor Property | Short Description |
---|---|
dbid | The database ID of an external Adabas database |
fnr | The file number of an external Adabas database. |
encoding | The encoding for the node and its children. Default is ISO-8859-1. |
password | The user password for the Adabas file to be accessed.
Important: |
ignoreUpdate | Value "true" means the contents of the node cannot be updated by loading instances using Tamino. Default is "false". |
Schema Editor Property | Short Description |
---|---|
Short name | Adabas group short name. |
Ignore update | Value "true" means the contents of the node cannot be updated by loading instances using Tamino. Default is "false". |
Schema Editor Property | Short Description |
---|---|
Short name | Adabas field short name. |
Format | The format of the field. |
Length | The length of the field. |
Encoding | The encoding for the node and its children. Default is
ISO-8859-1. The encoding is available when format
is "A".
|
Multiple | Value "true" means the node is mapped to an Adabas multiple value field. |
Ignore update | Value "true" means the contents of the node cannot be updated by loading instances using Tamino. Default is "false". |
The following illustrates the mapping of a node middlename
to an Adabas multiple value field (MU):
.... <xs:element name = "middlename" type = "xs:string" minOccurs = "0" maxOccurs = "unbounded"> <xs:annotation> <xs:appinfo> <tsd:elementInfo> <tsd:physical> <tsd:map> <tsd:nodeAdabasField shortname = "mn" format = "A"> <tsd:multiple></tsd:multiple> </tsd:nodeAdabasField> <tsd:ignoreUpdate></tsd:ignoreUpdate> </tsd:map> </tsd:physical> </tsd:elementInfo> </xs:appinfo> </xs:annotation> </xs:element> ....
Elements and attributes of XML documents can be mapped to server
extensions by specifying Map XTension
as the
storage type.
Schema Editor Property | Short Description |
---|---|
On Delete | The name of the server extension function that is to be executed when the node is processed on delete. |
On Compose | The name of the server extension function that is to be executed when the node is processed on retrieval. |
On Process | The name of the server extension function that is to be executed when the node is processed on storage. |
On Update |
The name of the server extension function that is to be executed when the node is processed on update. |
Ignore Update | Value "true" means the node cannot be updated by loading instances using Tamino. Default is "false". |
The required server extension can be selected from a dialog box. See Server Extensions for further information.
The following illustrates the declaration for an element
discharged
that contains information about a
hospital patient. When an instance of this element is deleted from the
database, an SXS function called SXSnotify is triggered.
An example of the function could be a message sent to the hospital
administration that triggers the building of an invoice and marking the
patient’s bed as vacant.
<xs:element name = "discharged" maxOccurs = "unbounded"> <xs:annotation> <xs:appinfo> <tsd:elementInfo> <tsd:physical> <tsd:map> <tsd:xTension> <tsd:onDelete>SXSnotify</tsd:onDelete> </tsd:xTension> </tsd:map> </tsd:physical> </tsd:elementInfo> </xs:appinfo> </xs:annotation> .... .... </xs:element> .... ....
For some element types, an
button is provided. When you choose this button, additional information is shown. You can then define the physical properties of a node that can be accessed via multiple paths.The following buttons are provided for defining the paths:
Add a new path. | |
Delete the selected path. |
You can define paths to the node, and for each set of paths, the storage type and index. If multiple paths are specified in one input field, the paths have to be separated by a semicolon.
You must specify absolute XPath expressions, starting with the doctype. The syntax for the path is as follows:
/doctype-name/element-name/../{current-element-name | @current-attribute-name}
Example:
/patient/name/surname
The path must be valid, i.e. it must point to an existing element.
For all paths not specified here, you can define a default storage type and index. You can use the default for elements without recursion. If recursion is used, the default only applies for the first recursion level.
The Tamino schema construct generated is a tsd:which
element.