This section describes the DDL commands pertaining to annotations.
Define a new annotation.
[ WITH with-item [, ...] ]
CREATE ABSTRACT [ INHERITABLE ] ANNOTATION name
[ "{"
CREATE ANNOTATION annotation-name := value ;
[...]
"}" ] ;
CREATE ABSTRACT ANNOTATION
defines a new annotation for use in the
current database.
If name is qualified with a module name, then the annotation is created in that module, otherwise it is created in the current module. The annotation name must be distinct from that of any existing schema item in the module.
The annotations are non-inheritable by default. That is, if a schema item has an annotation defined on it, the descendants of that schema item will not automatically inherit the annotation. Normal inheritance behavior can be turned on by declaring the annotation with the INHERITABLE qualifier.
Most sub-commands and options of this command are identical to the
SDL annotation declaration.
There’s only one subcommand that is allowed in the CREATE
ANNOTATION
block:
Annotations can also have annotations. Set the
annotation-name of the
enclosing annotation to a specific value.
See CREATE ANNOTATION
for details.
Change the definition of an annotation.
ALTER ABSTRACT ANNOTATION name
[ "{" ] subcommand; [...] [ "}" ];
where subcommand is one of
RENAME TO newname
CREATE ANNOTATION annotation-name := value
ALTER ANNOTATION annotation-name := value
DROP ANNOTATION annotation-name
The name (optionally module-qualified) of the annotation to alter.
The following subcommands are allowed in the ALTER ABSTRACT ANNOTATION
block:
Change the name of the annotation to newname.
Annotations can also have annotations. Change
annotation-name to a specific
value. See ALTER ANNOTATION
for
details.
Annotations can also have annotations. Remove annotation
annotation-name.
See DROP ANNOTATION
for details.
All the subcommands allowed in the CREATE ABSTRACT ANNOTATION
block are also valid subcommands for ALTER ANNOTATION
block.
Remove a schema annotation.
[ WITH with-item [, ...] ]
DROP ABSTRACT ANNOTATION name ;
Define an annotation value for a given schema item.
CREATE ANNOTATION annotation-name := value
Alter an annotation value for a given schema item.
ALTER ANNOTATION annotation-name := value
Remove an annotation from a given schema item.
DROP ANNOTATION annotation-name ;