Version Resolution for Generated Views
Version resolution determines which version of the repository object is included in a view when there are multiple versions to choose from. Version resolution does not apply to Workspace views. A Workspace view contains whatever version of the object is included in the workspace.
Version Resolution Strategy
When generating a view, the repository engine selects the last version of every object. Depending on the combination of versions and relationships that exist, this strategy can exclude some versions from the view, even if they are related to a version that is in the view.
For example, suppose you define a view that contains version one of ObjectA (VersionA1), which is related to version one of ObjectB (VersionB1). If VersionB1 has a successor, VersionB2, the repository engine selects VersionA1 and VersionB2 for the view. Because there is no relationship between VersionA1 and VersionB2, the generated view does not reflect the relationship.
Because view definitions resolve to a single version, version identifiers are not usually included in a view. However, views that use IRepositoryODBC::ExecuteQuery to run directly against the underlying database system may need the VersionID column for a subsequent GetObject operation. To handle this case, you can include the VersionID column in the view. This column indicates which version of an object is selected by version resolution. You can include the VersionID column by setting the USE_VERSIONID_COLUMN flag on the view definition interface.