ctdbGetActiveDatabaseUID
Retrieve the database UID, given the handle of an "active" (connected) database.
Declaration
CTDBRET ctdbGetActiveDatabaseUID(CTHANDLE Handle, pULONG puid)
Description
ctdbGetActiveDatabaseUID() retrieves the database Unique Identifier, UID, given the Database Handle. Note that the UID of a database persists as long as that database remains in the session dictionary. Removing a database from a session dictionary and then re-adding it to the session dictionary is very likely to change that database’s UID. Use ctdbGetDatabaseUID() to retrieve the database UID, given the database name. Use ctdbFindDatabaseByUID() to locate a database in a session by its unique identifier.
Returns
ctdbGetActiveDatabaseUID() returns CTDBRET_OK on success, or FairCom DB API error on failure.
See also
ctdbAllocDatabase(), ctdbFindDatabaseByUID(), ctdbGetDatabaseUID()