Annotations - Data Control API
The annotation functionality lets you create annotations and assign them to values in the table. Annotations can be assigned to various table components such as databases, fields, field values, and data cells (cross section of two or more field values).
An annotation contains two parts:
- Annotation symbol assignments - This is used to associate an annotation symbol with a table item.
- Annotation description -This contains detailed descriptive information for the annotation symbol.
Annotations can be assigned to the following elements within a table:
- Database - Setting an annotation for a database. The symbol will display in the title, next to the database name.
- Field - Setting an annotation for a field. The field can be across-tabulation or measure field. This annotation will display next to the field name in the table's title.
- Field value (category) - Setting an annotation for a field value. The field must be across-tabulation field. This annotation will display next to that value in the column, row or wafer of the table.
- Data cell:
- Setting an annotation for a combination of field values. The symbol will display in all the cells that correspond to this combination.
- Setting an annotation for a combination of field values and a measure field. The symbol will display in all the cells that correspond to this combination.
Static Annotations
The Data Control API contains a Static Annotations Plugin that can be used with static annotations. Use the annotation reference topics to configure the static annotations.
SuperSERVER stores static annotations and annotation assignments in a relational database system called the static annotation repository. The static annotation repository uses a Public Domain relational database implementation, SQLite, available from http://www.sqlite.org .
Dynamic Annotations
Annotations can be added to the table dynamically during cross-tabulation by using the Data Control API callback functions (see Module Callback API - Data Control API for more information).
Defining an Annotation Assignment
Database
A database annotation assignment can be defined by associating a database identifier with at least one annotation symbol. It can be described as:
[Database identifier] → [symbol, symbol , ...]
Field
Annotation assignment on a cross-tabulation/measure field can be defined by associating a field identifier with at least one annotation symbol. A cross-tabulation/measure identifier consists of a table name to which this field belongs and a field name. This assignment can be described as:
[Table Name, Field Name] → [symbol, symbol,, ...]
Field value (category)
Annotation assignment on a field value (category) can be defined by associating the field value identifier with at least one annotation symbol. A field value identifier consists of a table name to which this field belongs, a field name, a value set name and a value set value code. This assignment can be described as:
[Table Name, Field Name, Value Set Name, Value Set Value Code] → [symbol, symbol, ...]
Data cell
Annotation assignment on a data cell can be defined by associating a combination described in Table Items with at least one annotation symbol. The assignment can be described as:
[ (Table Name, Field Name, Value Set Name, Value Set Value Code)+] → [symbol, symbol, ...]
and
[ (Table Name, Field Name, Value Set Name, Value Set Value Code)+, (Table Name, Field Name) ] →
[symbol, symbol, ...]
A measure field can only be described as (Table Name, Field Name).