Key(ID) Management
Sequences: VY_OBJECTSEQUENCE, VY_CONNECTIONSEQUENCE, VY_ACCOUNTSEQUENCE
Table: VY_EXTERNALKEY
In the Vine Server database each record (row) of each table has a numeric ID. The IDs are created or changed when:
- When the database is being set up or updated. Permanent tables, such as VY_OBJECT or VY_TABLE, are filled during the database setup. Their contents, together with record IDs, are imported by Vine Manager from the OM_Objects_"Language name".txt file.
- When the database structure is being modified. The database administrator is able to create new object parameters, connection types and so on. Entering a new parameter, the administrator can also enter its ID.
- When new user objects or connections are being created. For maintaining the IDs of user objects and connections, the Vine database has two sequences: VY_OBJECTSEQUENCE and VY_CONNECTIONSEQUENCE. These sequences permit automatic creating of unique IDs. They specify that the object IDs start from 300000000 and the connection IDs - from 100000000.
Key Management Tables
SEQUENCES
- VY_ACCOUNTSequence is a key sequence for the local database accounts
- VY_ObjectSequence is a key sequence for the database objects, it starts from 300000000
- VY_ConnectionSequence is a key sequence for the connections, it starts from 100000000
External Keys
The VY_EXTERNALKEY table makes it possible to update the Vine database with data from external databases/sources.
Typically, objects of external data are identified by their own IDs. Vine products use these IDs to refer to the data. The VY_EXTERNALKEY table maps external IDs to internal IDs.
It is possible that objects from different external sources have equal IDs. In order to avoid ambiguity the names of external databases are stored in the EXTERNALDB field.
For instance:
Table 2. Example of VY_EXTERNALKEY objects
VINEYARDID | OBJECTTYPE | EXTERNALID | EXTERNALDB |
150000155 | VY_PROJECT | 155444 | PROJECTDB |
150000166 | VY_PROJECT | 155446 | PROJECTDB |
110000024 | VY_COMPANY | 155446 | CUSTOMER_DB |
Note that second and third objects in the preceding table have equal external identifiers. They can be differentiated only by external database names. External database names are presented in the column EXTERNALDB.
Comments
0 comments
Please sign in to leave a comment.