SAND CDBMS Data Types
Dependencies Among Database Objects
Database objects that are defined with reference to other objects are said to be dependent on those objects. In SAND CDBMS SQL, dependent objects include the following:
- views and snapshot tables, which depend on the base tables included in the view definition
- constraints, which depend on the columns that participate in the constraints
- columns, which depend on the domains on which the column is defined
- linked tables, which depend on the connection object on which the table is defined.
In addition, any database object created by an authorization (except for the user password) is dependent on that authorization, and any object defined within a schema depends on that schema.
SAND CDBMS automatically tracks the dependencies among the objects in a given database, allowing for the enforcement of certain rules on dependent objects when the "parent" object is destroyed (using the DROP command). These rules are called drop behaviors.
Dependencies are an important consideration whenever a database object is destroyed or "dropped". In SAND CDBMS SQL, drop behavior is as follows:
- If no dependent objects exist, the drop is carried out.
- If dependent objects exist (or if objects exist that "belong" to / are contained by the specified object), the drop is not carried out.
In the latter case, all dependent objects must be dropped before the "parent" object can be dropped.