Locating objects uniquely

If an object cannot be uniquely identified by its name or identifier, you must specify its relationship within a hierarchy of objects, such as its ancestors or level in a drill-down path.

When you use both an object identifier and an object name to identify an object in MDL, the object identifier determines whether the object exists. If there is a conflict between the object name and object identifier, the object identifier is used to locate the object, and the name is then changed accordingly.

If the object does not already exist or is not uniquely identified by its object name or object identifier, then you must supply the additional information required to locate it, in the syntax for each verb.

For example, suppose you want to refer to a column that exists in your data source. If your model does not provide a unique object name or object identifier for that column, you must uniquely identify it by specifying the data source in which it exists.

Similarly, if you add a new category to a dimension, in the context of a drill-down path, a level, and a parent category, you must specify all of those objects to locate it precisely and uniquely.

On the other hand, when you refer to an existing category, even if you do not uniquely identify it by its object identifier, you only need to specify the dimension name. This is sufficient because category names are unique within dimensions, and dimension names are unique within models.

The following rules govern the identification and location of objects:

  • If the object already exists and is identified by its object identifier, then no other information is needed to locate the object in the model.
  • If the object already exists and is identified only by its object name, then Cognos® Transformer searches the model for an object with the same name and object type and uses the first one it finds.
  • If the object does not already exist, then there must be sufficient contextual information to locate it in the model precisely.