Skip to main content

%SYSTEM.DocDB

abstract class %SYSTEM.DocDB extends %SYSTEM.Help

The %SYSTEM.DocDB class provides an interface for managing Document Databases.

You can use it via the special $SYSTEM object:

You can call help to get a list of all entry points:

do $SYSTEM.DocDB.Help()

Method Inventory

Methods

classmethod CreateDatabase(databaseName As %String(MAXLEN="")="", documentType As %String(MAXLEN=200), resource As %String(MAXLEN="")) as %DocDB.Database
Create a new Database in the current namespace. If a Database of that name already exists then return an error. Accepts Database Name, Document Type, and Resource. Return value is an oref referencing the Database definition object.
classmethod DropAllDatabases() as %Library.DynamicArray
Delete all Databases defined in the current namespace and their currently visible extent (user data). Returns an array containing the names of all Databases successfully dropped.
classmethod DropDatabase(databaseName As %String(MAXLEN="")="") as %Library.Boolean
Delete the definition and currently visible extent of an existing Database. Return true if the Database exists and the drop is successful, false if the named Database does not exist. If an error is encountered during execution then an exception is thrown.
classmethod Exists(databaseName As %RawString = "") as %Boolean

Return 1 (true) if the databaseName database is defined in the current namespace, 0 (false) otherwise.

classmethod GetAllDatabases() as %Library.DynamicArray
Return an array (%Library.DynamicArray) containing the names of all Databases defined in the current namespace.
classmethod GetDatabase(databaseName As %String(MAXLEN="")="") as %DocDB.Database
Retrieve the Database definition, this includes the Name, Class, Resource and Document Type Class. If the requested Database does not exist then an exception is thrown. Returns an oref referencing the Database definition object.

Inherited Members

Inherited Methods

FeedbackOpens in a new tab