Skip to main content

Globals (Tools/APIs)

Manage globals programmatically (import, export, get size, set collation, configure mappings, and so on).

Background Information

InterSystems IRIS® data platform stores all data in its databases in globals. A single set of rules governs the names of globals and the names of their subscripts (that is, different languages do not have different rules). See Introduction to Globals and Using Globals.

You can define global mappings so that you can access data in a non-default location; see Configuring Namespaces. Typically you do this within the Management Portal.

The Management Portal also provides options for examining and managing globals. See Managing Globals.

Available Tools

The fundamental tool for working with globals is the ObjectScript language. In addition, InterSystems provides the following tools:

This structured system variable returns information about globals.

Availability: All namespaces.

Provides the following class methods:

  • Export()

  • Import()

Availability: All namespaces.

Enables you to see and modify properties of globals. It provides the methods like the following:

  • CheckIntegrity()

  • CollationSet()

  • GetGlobalSize()

  • GetGlobalSizeBySubscript()

  • KillRange()

  • And others

Availability: All namespaces.

Maintains extent definitions and globals registered for use by those extents. It includes the following methods:

  • GlobalUses()

  • GlobalsUsed()

The %ExtentMgr tables are visible to SQL and can be queried directly. For details, see the reference for %ExtentMgr.UtilOpens in a new tab.

Availability: All namespaces.

Provides the following queries:

  • DirectoryList()

  • NameSpaceList()

  • NameSpaceListChui()

  • Size()

Availability: All namespaces.

Provides an interface to globals. It includes methods like the following:

  • GlobalListClose()

  • Kill()

  • Set()

  • And others

It also provides a couple of queries.

Availability: All namespaces.

Provides the following methods that you can use with globals:

  • Export()

  • ExportToStream()

  • Load()

Availability: All namespaces.

Enables you to modify and obtain information about the [] section of the CPF, which defines global mappings. (Note that you usually perform this configuration via the Management Portal, as noted above.)

The class also provides the List() class query.

The class documentation includes examples and details.

Availability: %SYS namespace.

%Installer.ManifestOpens in a new tab class and other classes in the %Installer package

Enable you to define and use an installation manifest. Among other tasks, you can configure global mappings.

Availability: All namespaces.


The special variable $SYSTEM is bound to the %SYSTEM package. This means that instead of ##class(%SYSTEM.class).method(), you can use $SYSTEM.class.method().

FeedbackOpens in a new tab