Component Table

[This is preliminary documentation and subject to change.]

The Component table lists components.

The Component table has the following columns.

Column Type Key Nullable
Component Identifier Y N
ComponentID GUID Y
Directory_ Identifier N
Attributes Integer N
Condition Condition Y
KeyPath Identifier Y

Columns

Component
Identifies the component record.

Primary table key.

ComponentID
A string GUID unique to this component, version, and language.

Table key.

Directory_
External key of an entry in the Directory table. This is a property name whose value contains the actual path, set either by the AppSearch action or with the default setting obtained from the Directory table.

External key to column one of the Directory table.

Attributes
Remote execution option.

The first two bits indicate whether the component can be run from source. The following table lists valid values.
This value Indicates that the item
0 (irsLocalOnly) Cannot be run from the source.
1 (irsSourceOnly) Can run only from the source.
2 (irsOptional) Can run either locally or from the source.

The rest of the significant bits are bit flags.

The 3rd bit is the irsRegistryKeyPath bit.

If the third bit is set, the KeyPath column, if not Null, is interpreted as a key into the Registry table. If this bit is not set, the KeyPath column, if not Null, is interpreted as a key into the File table.

The 4th bit is the icaSharedDllRefCount bit. If the 4th bit is set, the installer will always increment the reference count in the shared DLL registry. If the 4th bit is not set, then the installer will only increment the reference count if it already exists.

The 5th bit is the icaPermanent bit. If the 5th bit is set then the component will not be removed on uninstall.

Condition
A conditional statement that indicates if a component should be installed. If the condition is Null or evaluates to True, the component is enabled. If the condition evaluates to False, the component is disabled. If a component is disabled, it will not be installed regardless of the Action state associated with the component. For information on the conditional expression syntax, see the MsiEvaluateCondition function.
KeyPath
This value points to the component member that will be used for detection. It is also the path that is returned by the MsiGetComponentPath function. If not Null, KeyPath is either the primary key into the File table or the Registry table based on the irsRegistryKeyPath bit in the Attributes column. In both cases, the entity (file or folder) should belong to this component. If Null, the folder of the Component (Component.Directory_) is used as the key path. Two components can not share the same key path value.

Remarks

For a discussion of the relationship between components and features, see Feature Table.

The installer keeps track of shared DLLs independently of the shared DLL reference count in the registry. If a reference count for a shared DLL exists in the registry, then the installer will always increment the count when it is installing the file and decrement it when it is uninstalling. However, if the icaSharedDllRefCount bit is not set and the reference count does not already exist, the installer will not create one.

If the icaSharedDllRefCount bit is not set, another application could remove the component even if it is still needed. To see how this could happen, consider the following scenario:

To avoid this behavior, set the icaSharedDllRefCount bit.