rdmdbapi.h File Reference

Header for the RDM Database APIs. More...

#include "rdmtypes.h"#include "rdmrowidtypes.h"#include "rdmtfstypes.h"
Include dependency graph for rdmdbapi.h:
This graph shows which files directly or indirectly include this file:

Functions

RDM_RETCODE rdm_dbAllocCursor (RDM_DB db, RDM_CURSOR *pCursor)
Allocate a cursor. More...
RDM_RETCODE rdm_dbAlterCatalog (RDM_DB db, const RDM_TCHAR_T *ddlStmt)
Process a schema DDL command. More...
RDM_RETCODE rdm_dbClearCache (RDM_DB db)
RDM_RETCODE rdm_dbClose (RDM_DB db)
Close the database associated with a database handle. More...
RDM_RETCODE rdm_dbDeleteAllRowsFromDatabase (RDM_DB db)
Remove all rows from a database. More...
RDM_RETCODE rdm_dbDeleteAllRowsFromTable (RDM_DB db, RDM_TABLE_ID tableId)
Remove all rows from a table. More...
RDM_RETCODE rdm_dbEncrypt (RDM_DB db, RDM_ENCRYPT enc, const RDM_TCHAR_T *optString)
Encrypt a database. More...
RDM_RETCODE rdm_dbEnd (RDM_DB db)
End a transactional operation. More...
RDM_RETCODE rdm_dbEndRollback (RDM_DB db)
End and rollback a transactional operation. More...
RDM_RETCODE rdm_dbExport (RDM_DB db, const RDM_TCHAR_T *optString)
Database export API. More...
RDM_RETCODE rdm_dbVacuum (RDM_DB db, const RDM_TCHAR_T *optString)
Database vacuum API. More...
RDM_RETCODE rdm_dbFlushIdIndex (RDM_DB db)
Flush the database ID Index. More...
RDM_RETCODE rdm_dbRebuildIdIndex (RDM_DB db)
Rebuild the database ID Index. More...
RDM_RETCODE rdm_dbCreateNewPackFile (RDM_DB db)
Create a new pack file. More...
RDM_RETCODE rdm_dbFree (RDM_DB db)
Free a database handle. More...
RDM_RETCODE rdm_dbGetEncrypt (RDM_DB db, RDM_ENCRYPT *enc)
Get the encryption context associated with a database handle. More...
RDM_RETCODE rdm_dbGetLockStatus (RDM_DB db, RDM_TABLE_ID tableId, RDM_LOCK_STATUS *status)
Get the RDM_DB handle's current lock status of a table. More...
RDM_RETCODE rdm_dbGetOption (RDM_DB db, const RDM_TCHAR_T *keyword, RDM_TCHAR_T *optValue, size_t bytesIn, size_t *bytesOut)
Get a single database option into a string. More...
RDM_RETCODE rdm_dbGetOptions (RDM_DB db, RDM_TCHAR_T *optString, size_t bytesIn, size_t *bytesOut)
Get RDM database specific options. More...
RDM_RETCODE rdm_dbGetInfo (RDM_DB db, const RDM_TCHAR_T *keyword, RDM_TCHAR_T *infoString, size_t bytesIn, size_t *bytesOut)
Get RDM database information. More...
RDM_RETCODE rdm_dbGetRows (RDM_DB db, RDM_TABLE_ID tableId, RDM_CURSOR *pCursor)
Associate an RDM_CURSOR with rows based on a table id. More...
RDM_RETCODE rdm_dbGetRowsAtRowId (RDM_DB db, RDM_TABLE_ID tableId, RDM_ROWID_T rowId, RDM_CURSOR *pCursor)
Associate an RDM_CURSOR with rows based on a tableId and and rowId. More...
RDM_RETCODE rdm_dbGetRowsByKey (RDM_DB db, RDM_KEY_ID keyId, RDM_CURSOR *pCursor)
Associate an RDM_CURSOR with a row set based on a key. More...
RDM_RETCODE rdm_dbGetRowsByKeyAtKey (RDM_DB db, RDM_KEY_ID keyId, const void *keyValue, size_t len, RDM_CURSOR *pCursor)
Associate an RDM_CURSOR with a row set that is ordered by key value and is initially positioned at the specified key value. More...
RDM_RETCODE rdm_dbGetRowsByKeyAtSearchKey (RDM_DB db, RDM_KEY_ID keyId, const RDM_SEARCH_KEY *keyValue, RDM_CURSOR *pCursor)
Associate an RDM_CURSOR with a row set that is ordered by key value and is initially positioned at the specified key value. More...
RDM_RETCODE rdm_dbGetRowsByKeyInKeyRange (RDM_DB db, RDM_KEY_ID keyId, const void *startValue, size_t bytesInStartValue, const void *endValue, size_t bytesInEndValue, RDM_CURSOR *pCursor)
Associate an RDM_CURSOR with rows in a specified key range. More...
RDM_RETCODE rdm_dbGetRowsByKeyInRangeKeyRange (RDM_DB db, RDM_KEY_ID keyId, const RDM_RANGE_KEY *startValue, const RDM_RANGE_KEY *endValue, RDM_CURSOR *pCursor)
Associate an RDM_CURSOR with rows in a specified key range. More...
RDM_RETCODE rdm_dbGetRowsByKeyInRtreeKeyRange (RDM_DB db, RDM_KEY_ID keyId, const RDM_RTREE_KEY *keyValue, RDM_CURSOR *pCursor)
Associate an RDM_CURSOR with a row set based on a r-tree. More...
RDM_RETCODE rdm_dbGetRowsByKeyInSearchKeyRange (RDM_DB db, RDM_KEY_ID keyId, const RDM_SEARCH_KEY *startValue, const RDM_SEARCH_KEY *endValue, RDM_CURSOR *pCursor)
Associate an RDM_CURSOR with rows in a specified key range. More...
RDM_RETCODE rdm_dbGetTFS (RDM_DB db, RDM_TFS *pTFS)
Get the RDM_TFS handle associated with a db. More...
RDM_RETCODE rdm_dbGetTFSType (RDM_DB db, TFS_TYPE *pTfsType)
Get the type of the RDM_TFS handle associated with a database. More...
RDM_RETCODE rdm_dbGetTransactionStatus (RDM_DB db, RDM_TRANS_STATUS *status)
Get the transaction status for a database handle. More...
RDM_RETCODE rdm_dbImport (RDM_DB db, const RDM_TCHAR_T *optString)
Database import API. More...
RDM_RETCODE rdm_dbInsertRow (RDM_DB db, RDM_TABLE_ID tableId, const void *colValues, size_t bytesIn, RDM_CURSOR *pCursor)
Insert a new row into a table at the specified rowId. More...
RDM_RETCODE rdm_dbInsertRows (RDM_DB db, RDM_TABLE_ID tableId, const void *colValues, size_t bytesIn, uint32_t num, RDM_CURSOR *pCursorStatus, RDM_CURSOR *pCursor)
Insert rows into a table. More...
RDM_RETCODE rdm_dbOpen (RDM_DB db, const RDM_TCHAR_T *db_namespec, RDM_OPEN_MODE mode)
Open an existing RDM database using the specified database handle. More...
RDM_RETCODE rdm_dbPersistInMemory (RDM_DB db)
Persist in-memory tables to disk. More...
RDM_RETCODE rdm_dbPrecommit (RDM_DB db)
Precommit a transactional operation. More...
RDM_RETCODE rdm_dbRebuildKey (RDM_DB db, RDM_KEY_ID keyId, uint32_t reportFrequency, RDM_REBUILD_INDEX_REPORT_FCN *fcn)
Rebuild keys for an index. More...
RDM_RETCODE rdm_dbRebuildKeys (RDM_DB db, uint32_t numKeys, const RDM_KEY_ID *keyId, uint32_t reportFrequency, RDM_REBUILD_INDEX_REPORT_FCN *fcn)
Rebuild keys for one or more indexes. More...
RDM_RETCODE rdm_dbReinsertRow (RDM_DB db, RDM_TABLE_ID tableId, RDM_ROWID_T rowId, const void *colValues, size_t bytesIn, RDM_CURSOR *pCursor)
Insert a new row into a table. More...
RDM_RETCODE rdm_dbSetCatalog (RDM_DB db, const RDM_TCHAR_T *catalog)
Associate a catalog with an allocated database. More...
RDM_RETCODE rdm_dbSetCatalogFromFile (RDM_DB db, const RDM_TCHAR_T *catfile)
Associate a catalog with an allocated database. More...
RDM_RETCODE rdm_dbSetEncrypt (RDM_DB db, RDM_ENCRYPT enc)
Associate an encryption context with a database handle. More...
RDM_RETCODE rdm_dbSetErrorHandler (RDM_DB db, RDM_ERROR_FCN errorFunction, void *userData)
Replace default error reporting with a custom function. More...
RDM_RETCODE rdm_dbSetOption (RDM_DB db, const RDM_TCHAR_T *keyword, const RDM_TCHAR_T *strValue)
Set a single RDM option from a string. More...
RDM_RETCODE rdm_dbSetOptions (RDM_DB db, const RDM_TCHAR_T *optString)
Set RDM options. More...
RDM_RETCODE rdm_dbStartRead (RDM_DB db, const RDM_TABLE_ID *tableIds, uint32_t numTableIds, RDM_TRANS *pTrans)
Get read locks. More...
RDM_RETCODE rdm_dbStartSnapshot (RDM_DB db, const RDM_TABLE_ID *tableIds, uint32_t numTableIds, RDM_TRANS *pTrans)
Start a snapshot. More...
RDM_RETCODE rdm_dbStartUpdate (RDM_DB db, const RDM_TABLE_ID *writeTableIds, uint32_t numWriteTableIds, const RDM_TABLE_ID *readTableIds, uint32_t numReadTableIds, RDM_TRANS *pTrans)
Get write locks. More...
RDM_RETCODE rdm_dbTriggersOff (RDM_DB db)
Disable use of triggers for an open database. More...
RDM_RETCODE rdm_dbTriggersOn (RDM_DB db)
Enable use of triggers for an open database. More...
RDM_RETCODE rdm_dbTriggersStatus (RDM_DB db, RDM_TRIGGERS_STATUS *pStat)
Check the triggers use status for a database. More...
RDM_RETCODE rdm_dbRepair (RDM_DB db, const RDM_TCHAR_T *optString)

Detailed Description

Header for the RDM Database APIs.

Function Documentation

rdm_dbClearCache()

RDM_RETCODE rdm_dbClearCache ( RDM_DB db )
Parameters
[in] db [in] A valid RDM database handle

rdm_dbRepair()

RDM_RETCODE rdm_dbRepair ( RDM_DB db,
const RDM_TCHAR_T * optString
)
Parameters
[in] db [in] A valid RDM database handle
[in] optString [in] A semicolon delimited string that contains the utility options