Skip to main content

This is documentation for Caché & Ensemble. See the InterSystems IRIS version of this content.

For information on migrating to InterSystems IRIS, see How to Migrate to InterSystems IRIS, available on the WRC Distributions page (login required).

IdLocation

Specifies location of the ID counter.

Synopsis

<IdLocation>^Sample.PersonD</IdLocation>

Value

The value of this element is a global name with optional leading subscripts.

Description

This element lets you specify the global node that contains the counter used to assign object ID values.

By default, in a persistent class definition using default storage, this global location contains the highest assigned ID for an instance of the class. However this applies only if the <IdFunction> element is set to increment and the class does not use an IdKey. The value stored at this global location is not meaningful if the <IdFunction> element is set to sequence, and the location is not assigned a value if the class uses an IdKey.

Default Value

If not specified, a value for the <IdLocation> element is generated by the class compiler. Often, the value is ^MyApp.MyClassD (where MyApp.MyClass is the class name), however, it may vary based on a number of factors. For more information on global names for persistent classes, see “Globals” in the chapter “Introduction to Persistent Objects” in Using Caché Objects.

Feedback