As explained in the previous section, in order to modify and update the CAST Analysis Service, a set of entry tables must be injected with data that defines how the CAST Analysis Service will be altered.

Entry tables

The following is an exhaustive list of entry tables ordered by function:

Error management:

Object modification:

Parent type link modification:

Object property modification:

Link modification:

Each table and its function is described in more detail below.

CI_ERRORS

This table will be injected with data if any errors or data inconsistencies are found during the data check process (this takes place when the job is executed).

Column

Type (Length)

Null

Misc.

ERROR_ID

int

Not Null

 

CATEGORY

int

Not Null

 

MESSAGE

varchar(500)

Not Null

 

Note also that all other tables have an ERROR_ID column, which will be used if any errors or data inconsistencies are found during the data check process. You can find out more about how errors are handled and how you can debug them in chapter Error handling .

GUID_OBJECTS

When the results of a CAST analysis are stored in the CAST Analysis Service, all objects (regardless of the analyzer type) are always given a unique numerical OBJECT_ID to identify the object – this OBJECT_ID is then used throughout the Analysis Service to identify the object. At the same time, some objects are also given a unique OBJECT_GUID to provide more details about the object, however, this is not the case for the results of all CAST analyzers. The results of the following CAST analyzers are given an OBJECT_ID and an OBJECT_GUID:

You can query the CAST System View "CTV_GUID_OBJECTS" (providing the view is up-to-date) to see which objects have an OBJECT_GUID and which do not.

The Update CAST Knowledge Base Tool always requires an object's OBJECT_GUID to function correctly and to determine which object your update is being performed on. As a result, if any of the objects involved in the update do NOT have an OBJECT_GUID, then you must either:

Thus, to conclude, the GUID_OBJECTS table only needs to be filled with data when you want to modify objects that do NOT have an OBJECT_GUID and you want to create the OBJECT_GUID manually yourself. If you are using the OBJECT_ID (as oppose to the OBJECT_GUID), then you do not need to enter values in the GUID_OBJECTS table.

Note that this Admin Guide provides details on how to work with both the OBJECT_GUID and the OBJECT_ID.

Column

Type (Length)

Null

Misc.

OBJECT_ID

int

Null

== the real IdKey from the table Keys

OBJECT_GUID

varchar(1015)

Null

 

OBJECT_SHORTGUID

varchar (600)

Null

Not currently used

ERROR_ID

int

Not Null

== send 0

To find out more about OBJECT_GUIDs, how to create them and the naming convention in use, please see Creating OBJECT_GUIDs .

CI_OBJECTS

This table is used when you want to add a new object to the CAST Analysis Service.

Column

Type (Length)

Null

Misc.

OBJECT_GUID

varchar(590)

Not Null

 

OBJECT_TYPE

varchar(255)

Not Null

 

OBJECT_NAME

varchar(255)

Not Null

 

OBJECT_FULLNAME

varchar(255)

Not Null

 

ERROR_ID

int

Not Null

== send 0

Note that with regard to defining the column OBJECT_TYPE, you must retrieve the existing type (use a CAST System View to do so):

select TYPE_NAME, TYPE_DESCRIPTION
from CTV_OBJECT_TYPES

CI_NO_OBJECTS

This table is used when you want to remove an existing object from the CAST Analysis Service. You must enter either an OBJECT_ID or an OBJECT_GUID.

Column

Type (Length)

Null

Misc.

OBJECT_ID

int

Null

 

OBJECT_GUID

varchar(1015)

Null

 

OBJECT_SHORTGUID

varchar (600)

Null

Not currently used

ERROR_ID

int

Not Null

== send 0

CI_PARENTS

This table is used when you want to add a parent type link (Belongs To) to an existing object. You must enter either a PARENT_ID or a PARENT_GUID.

Column

Type (Length)

Null

Misc.

OBJECT_GUID

varchar(590)

Not Null

 

PARENT_ID

int

Null

 

PARENT_GUID

varchar(1015)

Null

 

PARENT_SHORTGUID

 

varchar(600)

 

Null

Not currently used

ERROR_ID

int

Not Null

== send 0

Please note that if you add parent type links to existing objects and then re-launch the analysis job that created the existing objects, the parent type links you added will be destroyed.

CI_STR_PROPERTIES

This table is used when you want to modify/add an existing object's alphanumeric property (for example object comments or business functions). You must enter either an OBJECT_ID or an OBJECT_GUID.

Column

Type (Length)

Null

Misc.

OBJECT_ID

int

Null

 

OBJECT_GUID

varchar(1015)

Null

 

OBJECT_SHORTGUID

varchar(600)

Null

 

PROP_NAME

varchar(255)

Not Null

 

ORDER_NUMBER

int

Not Null

== starts at 1

VALUE

varchar(590)

Not Null

 

ERROR_ID

int

Not Null

== send 0

Note that with regard to defining the column PROP_NAME, use a CAST System View to retrieve the existing property name you require:

select PROP_NAME, PROP_DESCRIPTION
from CTV_PROPERTIES

The column ORDER_NUMBER is used to split properties with a VALUE string size above 255 characters. For example if the VALUE of the property you wanted to add or modify was (for example) 389 characters, you would need to add two rows that contained the split comment as follows. The first row contains the first 253 characters of the property, the second row contains the last 135 characters, differentiated by the value in the ORDER_NUMBER column:

CI_INT_PROPERTIES

This table is used when you want to modify/add an existing object's numeric property (for example the number of inner comment lines, number of code lines etc.). You must enter either an OBJECT_ID or an OBJECT_GUID.

Column

Type (Length)

Null

Misc.

OBJECT_ID

int

Null

 

OBJECT_GUID

varchar(1015)

Null

 

OBJECT_SHORTGUID

varchar(600)

Null

Not currently used

PROP_NAME

varchar(255)

Not Null

 

VALUE

int

Not Null

 

ERROR_ID

int

Not Null

== send 0

Note that with regard to defining the column PROP_NAME, use a CAST System View to retrieve the existing property name you require:

select PROP_NAME, PROP_DESCRIPTION
from CTV_PROPERTIES

CI_NO_PROPERTIES

This table is used when you want to delete an existing object's property (for example the number of inner comment lines, number of code lines etc.). You must enter either an OBJECT_ID or an OBJECT_GUID.

Column

Type (Length)

Null

Misc.

OBJECT_ID

int

Null

 

OBJECT_GUID

varchar(1015)

Null

 

OBJECT_SHORTGUID

varchar(600)

Null

Not currently used

PROP_NAME

varchar(255)

Not Null

 

ERROR_ID

int

Not Null

== send 0

Note that with regard to defining the column PROP_NAME, use a CAST System View to retrieve the existing property name you require:

select PROP_NAME, PROP_DESCRIPTION
from CTV_PROPERTIES

CI_NO_LINKS

This table is used when you want to remove an existing link between two existing objects). You must enter either a CALLER_ID/CALLED_ID pair or a CALLER_GUID/CALLED_GUID pair.

Column

Type (Length)

Null

Misc.

CALLER_ID

int

Null

 

CALLER_GUID

varchar(1015)

Null

 

CALLER_SHORTGUID

varchar(600)

Null

Not currently used

CALLED_ID

int

Null

 

CALLED_GUID

varchar(1015)

Null

 

CALLED_SHORTGUID

varchar(600)

Null

Not currently used

ERROR_ID

int

Not Null

== send 0

CI_LINKS

This table is used when you want to add a link between two existing objects. You must enter either a CALLER_ID/CALLED_ID pair or a CALLER_GUID/CALLED_GUID pair.

Column

Type (Length)

Null

Misc.

CALLER_ID

int

Null

 

CALLER_GUID

varchar(1015)

Null

 

CALLER_SHORTGUID

varchar(600)

Null

Not currently used

CALLED_ID

int

Null

 

CALLED_GUID

varchar(1015)

Null

 

CALLED_SHORTGUID

varchar(600)

Null

Not currently used

LINK_TYPE

Varchar(255)

Not Null

 

ERROR_ID

int

Not Null

== send 0