Products Support Documentation Download
rdmdbapi.h
Go to the documentation of this file.
1 /* ----------------------------------------------------------------------------
2  * Raima Database Manager
3  *
4  * Copyright (c) 2014 Raima Inc., All rights reserved.
5  *
6  * Use of this software, whether in source code format, or in executable,
7  * binary object code form, is governed by the Raima LICENSE which
8  * is fully described in the LICENSE.TXT file, included within this
9  * distribution of files.
10  * ----------------------------------------------------------------------------
11  */
12 
13 /* PLEASE READ AND UNDERSTAND PRIOR TO MODIFYING THIS FILE
14  *
15  * This header file should contain the declarations for functions that are
16  * exported from the RDM runtime libarary as part of the published
17  * RDM_DB interface. These functions will be availabe for use by customers
18  * and other RDM modules, therefore they should all be declared with RDM_EXPORT
19  * and EXTERNAL_FCN.
20  *
21  * If the API takes a string as a parameter it should always use RDM_TCHAR_T
22  * and use a RDM_T_FUNC wrapper.
23  *
24  * This header file should only contain function definitions. Types,
25  * structures, enums etc. required for the RDM_DB interface (a parameter to one
26  * of the public APIs), should be declared in include/rdmtypes.h
27  *
28  */
29 
34 #include "rdmtypes.h"
35 #include "rdmrowidtypes.h"
36 #include "rdmtfstypes.h"
37 
38 #if defined(__cplusplus)
39 extern "C" {
40 #endif
41 
137 #if defined(RDM_UNICODE)
138 #define rdm_dbAlterCatalog RDM_T_FUNC (rdm_dbAlterCatalog)
139 #define rdm_dbEncrypt RDM_T_FUNC (rdm_dbEncrypt)
140 #define rdm_dbExport RDM_T_FUNC (rdm_dbExport)
141 #define rdm_dbGetOption RDM_T_FUNC (rdm_dbGetOption)
142 #define rdm_dbGetOptions RDM_T_FUNC (rdm_dbGetOptions)
143 #define rdm_dbGetInfo RDM_T_FUNC (rdm_dbGetInfo)
144 #define rdm_dbImport RDM_T_FUNC (rdm_dbImport)
145 #define rdm_dbOpen RDM_T_FUNC (rdm_dbOpen)
146 #define rdm_dbSetCatalog RDM_T_FUNC (rdm_dbSetCatalog)
147 #define rdm_dbSetCatalogFromFile RDM_T_FUNC (rdm_dbSetCatalogFromFile)
148 #define rdm_dbCompileCatalog RDM_T_FUNC (rdm_dbCompileCatalog)
149 #define rdm_dbCompileCatalogFromFile RDM_T_FUNC (rdm_dbCompileCatalogFromFile)
150 #define rdm_dbLoadCatalog RDM_T_FUNC (rdm_dbLoadCatalog)
151 #define rdm_dbLoadCatalogFromFile RDM_T_FUNC (rdm_dbLoadCatalogFromFile)
152 #define rdm_dbSetErrorHandler RDM_T_FUNC (rdm_dbSetErrorHandler)
153 #define rdm_dbSetOption RDM_T_FUNC (rdm_dbSetOption)
154 #define rdm_dbSetOptions RDM_T_FUNC (rdm_dbSetOptions)
155 #define rdm_dbVacuum RDM_T_FUNC (rdm_dbVacuum)
156 #endif
157 
185 RDM_EXPORT RDM_RETCODE EXTERNAL_FCN rdm_dbAllocCursor (
186  RDM_DB db,
187  RDM_CURSOR *pCursor
188 );
189 
230 RDM_EXPORT RDM_RETCODE EXTERNAL_FCN rdm_dbAlterCatalog (
231  RDM_DB db,
232  const RDM_TCHAR_T *ddlStmt
233 );
234 
235 RDM_EXPORT RDM_RETCODE EXTERNAL_FCN rdm_dbClearCache (
236  RDM_DB db
237 );
238 
260 RDM_EXPORT RDM_RETCODE EXTERNAL_FCN rdm_dbClose (
261  RDM_DB db
262 );
263 
296 RDM_EXPORT RDM_RETCODE EXTERNAL_FCN rdm_dbDeleteAllRowsFromDatabase (
297  RDM_DB db
298 );
299 
338 RDM_EXPORT RDM_RETCODE EXTERNAL_FCN rdm_dbDeleteAllRowsFromTable (
339  RDM_DB db,
341  tableId
342 );
343 
366 RDM_EXPORT RDM_RETCODE EXTERNAL_FCN rdm_dbGetMemoryUsage (
367  RDM_DB db,
368  uint64_t *systemCurr,
369  uint64_t *systemMax,
370  uint64_t *userCurr,
371  uint64_t *userMax
372 );
373 
405 RDM_EXPORT RDM_RETCODE EXTERNAL_FCN rdm_dbEncrypt (
406  RDM_DB db,
407  RDM_ENCRYPT enc,
408  const RDM_TCHAR_T *optString
410 );
411 
442 RDM_EXPORT RDM_RETCODE EXTERNAL_FCN rdm_dbEnd (
443  RDM_DB db
444 );
445 
478 RDM_EXPORT RDM_RETCODE EXTERNAL_FCN rdm_dbEndRollback (
479  RDM_DB db
480 );
481 
525 RDM_EXPORT RDM_RETCODE EXTERNAL_FCN rdm_dbExport (
526  RDM_DB db,
527  const RDM_TCHAR_T *optString
529 );
530 
550 RDM_EXPORT RDM_RETCODE EXTERNAL_FCN rdm_dbVacuum (
551  RDM_DB db,
552  const RDM_TCHAR_T *optString
554 );
555 
577 RDM_EXPORT RDM_RETCODE EXTERNAL_FCN rdm_dbFlushIdIndex (
578  RDM_DB db
579 );
580 
601 RDM_EXPORT RDM_RETCODE EXTERNAL_FCN rdm_dbRebuildIdIndex (
602  RDM_DB db
603 );
604 
627 RDM_EXPORT RDM_RETCODE EXTERNAL_FCN rdm_dbCreateNewPackFile (
628  RDM_DB db
629 );
630 
651 RDM_EXPORT RDM_RETCODE EXTERNAL_FCN rdm_dbFree (
652  RDM_DB db
653 );
654 
673 RDM_EXPORT RDM_RETCODE EXTERNAL_FCN rdm_dbGetEncrypt (
674  RDM_DB db,
675  RDM_ENCRYPT *enc
676 );
677 
715 RDM_EXPORT RDM_RETCODE EXTERNAL_FCN rdm_dbGetLockStatus (
716  RDM_DB db,
717  RDM_TABLE_ID tableId,
718  RDM_LOCK_STATUS *status
720 );
721 
741 RDM_EXPORT RDM_RETCODE EXTERNAL_FCN rdm_dbGetOption (
742  RDM_DB db,
743  const RDM_TCHAR_T *keyword,
744  RDM_TCHAR_T *optValue,
745  size_t bytesIn,
746  size_t *bytesOut
747 );
748 
771 RDM_EXPORT RDM_RETCODE EXTERNAL_FCN rdm_dbGetOptions (
772  RDM_DB db,
773  RDM_TCHAR_T *optString,
774  size_t bytesIn,
775  size_t *bytesOut
776 );
777 
798 RDM_EXPORT RDM_RETCODE EXTERNAL_FCN rdm_dbGetInfo (
799  RDM_DB db,
800  const RDM_TCHAR_T *keyword,
801  RDM_TCHAR_T *infoString,
802  size_t bytesIn,
803  size_t *bytesOut
804 );
805 
844 RDM_EXPORT RDM_RETCODE EXTERNAL_FCN rdm_dbGetRows (
845  RDM_DB db,
846  RDM_TABLE_ID tableId,
847  RDM_CURSOR *pCursor
849 );
850 
903 RDM_EXPORT RDM_RETCODE EXTERNAL_FCN rdm_dbGetRowsAtRowId (
904  RDM_DB db,
905  RDM_TABLE_ID tableId,
906  RDM_ROWID_T rowId,
907  RDM_CURSOR *pCursor
909 );
910 
955 RDM_EXPORT RDM_RETCODE EXTERNAL_FCN rdm_dbGetRowsByKey (
956  RDM_DB db,
957  RDM_KEY_ID keyId,
958  RDM_CURSOR *pCursor
960 );
961 
1026 RDM_EXPORT RDM_RETCODE EXTERNAL_FCN rdm_dbGetRowsByKeyAtKey (
1027  RDM_DB db,
1028  RDM_KEY_ID keyId,
1029  const void *keyValue,
1030  size_t len,
1031  RDM_CURSOR *pCursor
1033 );
1034 
1099 RDM_EXPORT RDM_RETCODE EXTERNAL_FCN rdm_dbGetRowsByKeyAtSearchKey (
1100  RDM_DB db,
1101  RDM_KEY_ID keyId,
1102  const RDM_SEARCH_KEY *keyValue,
1103  RDM_CURSOR *pCursor
1105 );
1106 
1176 RDM_EXPORT RDM_RETCODE EXTERNAL_FCN rdm_dbGetRowsByKeyInKeyRange (
1177  RDM_DB db,
1178  RDM_KEY_ID keyId,
1179  const void *startValue,
1180  size_t bytesInStartValue,
1181  const void *endValue,
1182  size_t bytesInEndValue,
1183  RDM_CURSOR *pCursor
1185 );
1186 
1250 RDM_EXPORT RDM_RETCODE EXTERNAL_FCN rdm_dbGetRowsByKeyInRangeKeyRange (
1251  RDM_DB db,
1252  RDM_KEY_ID keyId,
1253  const RDM_RANGE_KEY *startValue,
1254  const RDM_RANGE_KEY *endValue,
1255  RDM_CURSOR *pCursor
1257 );
1258 
1303 RDM_EXPORT RDM_RETCODE EXTERNAL_FCN rdm_dbGetRowsByKeyInRtreeKeyRange (
1304  RDM_DB db,
1305  RDM_KEY_ID keyId,
1306  const RDM_RTREE_KEY *keyValue,
1307  RDM_CURSOR *pCursor
1309 );
1310 
1376 RDM_EXPORT RDM_RETCODE EXTERNAL_FCN rdm_dbGetRowsByKeyInSearchKeyRange (
1377  RDM_DB db,
1378  RDM_KEY_ID keyId,
1379  const RDM_SEARCH_KEY *startValue,
1380  const RDM_SEARCH_KEY *endValue,
1381  RDM_CURSOR *pCursor
1383 );
1384 
1401 RDM_EXPORT RDM_RETCODE EXTERNAL_FCN rdm_dbGetTFS (
1402  RDM_DB db,
1403  RDM_TFS *pTFS );
1404 
1421 RDM_EXPORT RDM_RETCODE EXTERNAL_FCN rdm_dbGetTFSType (
1422  RDM_DB db,
1423  TFS_TYPE *pTfsType
1424 );
1425 
1461 RDM_EXPORT RDM_RETCODE EXTERNAL_FCN rdm_dbGetTransactionStatus (
1462  RDM_DB db,
1463  RDM_TRANS_STATUS *status
1465 );
1466 
1500 RDM_EXPORT RDM_RETCODE EXTERNAL_FCN rdm_dbImport (
1501  RDM_DB db,
1502  const RDM_TCHAR_T *optString
1504 );
1505 
1556 RDM_EXPORT RDM_RETCODE EXTERNAL_FCN rdm_dbInsertRow (
1557  RDM_DB db,
1558  RDM_TABLE_ID tableId,
1560  const void *colValues,
1566  size_t bytesIn,
1568  RDM_CURSOR *pCursor
1570 );
1571 
1620 RDM_EXPORT RDM_RETCODE EXTERNAL_FCN rdm_dbInsertRows (
1621  RDM_DB db,
1622  RDM_TABLE_ID tableId,
1624  const void *colValues,
1630  size_t bytesIn,
1631  uint32_t num,
1633  RDM_CURSOR *pCursorStatus,
1638  RDM_CURSOR *pCursor
1642 );
1643 
1705 RDM_EXPORT RDM_RETCODE EXTERNAL_FCN rdm_dbOpen (
1706  RDM_DB db,
1707  const RDM_TCHAR_T *dbNameSpec,
1708  RDM_OPEN_MODE mode
1709 );
1710 
1735 RDM_EXPORT RDM_RETCODE EXTERNAL_FCN rdm_dbPersistInMemory (
1736  RDM_DB db
1737 );
1738 
1765 RDM_EXPORT RDM_RETCODE EXTERNAL_FCN rdm_dbPrecommit (
1766  RDM_DB db
1767 );
1768 
1795 RDM_EXPORT RDM_RETCODE EXTERNAL_FCN rdm_dbRebuildKey (
1796  RDM_DB db,
1797  RDM_KEY_ID keyId,
1798  uint32_t reportFrequency,
1800  *fcn
1801 );
1802 
1829 RDM_EXPORT RDM_RETCODE EXTERNAL_FCN rdm_dbRebuildKeys (
1830  RDM_DB db,
1831  uint32_t numKeys,
1832  const RDM_KEY_ID *keyId,
1833  uint32_t reportFrequency,
1835  *fcn
1836 );
1837 
1890 RDM_EXPORT RDM_RETCODE EXTERNAL_FCN rdm_dbReinsertRow (
1891  RDM_DB db,
1892  RDM_TABLE_ID tableId,
1893  RDM_ROWID_T rowId,
1894  const void *colValues,
1900  size_t bytesIn,
1902  RDM_CURSOR *pCursor
1904 );
1905 
1937 RDM_EXPORT RDM_RETCODE EXTERNAL_FCN rdm_dbSetCatalog (
1938  RDM_DB db,
1939  const RDM_TCHAR_T
1940  *catalog
1941 );
1942 
1979 RDM_EXPORT RDM_RETCODE EXTERNAL_FCN rdm_dbSetCatalogFromFile (
1980  RDM_DB db,
1981  const RDM_TCHAR_T *catfile
1982 );
1983 
2014 RDM_EXPORT RDM_RETCODE EXTERNAL_FCN rdm_dbCompileCatalog (
2015  RDM_DB db,
2016  const RDM_TCHAR_T
2017  *schema
2018 );
2019 
2059 RDM_EXPORT RDM_RETCODE EXTERNAL_FCN rdm_dbCompileCatalogFromFile (
2060  RDM_DB db,
2061  const RDM_TCHAR_T *schemafile
2062 );
2063 
2096 RDM_EXPORT RDM_RETCODE EXTERNAL_FCN rdm_dbLoadCatalog (
2097  RDM_DB db,
2098  const RDM_TCHAR_T
2099  *catalog
2100 );
2101 
2140 RDM_EXPORT RDM_RETCODE EXTERNAL_FCN rdm_dbLoadCatalogFromFile (
2141  RDM_DB db,
2142  const RDM_TCHAR_T *catfile
2143 );
2144 
2170 RDM_EXPORT RDM_RETCODE EXTERNAL_FCN rdm_dbSetEncrypt (
2171  RDM_DB db,
2172  RDM_ENCRYPT enc
2174 );
2175 
2210 RDM_EXPORT RDM_RETCODE EXTERNAL_FCN rdm_dbSetErrorHandler (
2211  RDM_DB db,
2212  RDM_ERROR_FCN errorFunction,
2214  void *userData
2216 );
2217 
2242 RDM_EXPORT RDM_RETCODE EXTERNAL_FCN rdm_dbSetOption (
2243  RDM_DB db,
2244  const RDM_TCHAR_T *keyword,
2245  const RDM_TCHAR_T *strValue
2246 );
2247 
2286 RDM_EXPORT RDM_RETCODE EXTERNAL_FCN rdm_dbSetOptions (
2287  RDM_DB db,
2288  const RDM_TCHAR_T *optString
2289 );
2290 
2357 RDM_EXPORT RDM_RETCODE EXTERNAL_FCN rdm_dbStartRead (
2358  RDM_DB db,
2359  const RDM_TABLE_ID *tableIds,
2360  uint32_t numTableIds,
2361  RDM_TRANS *pTrans
2362 );
2363 
2400 RDM_EXPORT RDM_RETCODE EXTERNAL_FCN rdm_dbStartSnapshot (
2401  RDM_DB db,
2402  const RDM_TABLE_ID *tableIds,
2403  uint32_t numTableIds,
2404  RDM_TRANS *pTrans
2405 );
2406 
2502 RDM_EXPORT RDM_RETCODE EXTERNAL_FCN rdm_dbStartUpdate (
2503  RDM_DB db,
2504  const RDM_TABLE_ID *writeTableIds,
2505  uint32_t numWriteTableIds,
2506  const RDM_TABLE_ID *readTableIds,
2507  uint32_t numReadTableIds,
2508  RDM_TRANS *pTrans
2509 );
2510 
2529 RDM_EXPORT RDM_RETCODE EXTERNAL_FCN rdm_dbTriggersOff (
2530  RDM_DB db
2531 );
2532 
2555 RDM_EXPORT RDM_RETCODE EXTERNAL_FCN rdm_dbTriggersOn (
2556  RDM_DB db
2557 );
2558 
2584 RDM_EXPORT RDM_RETCODE EXTERNAL_FCN rdm_dbTriggersStatus (
2585  RDM_DB db,
2587  *pStat
2588 );
2589 
2590 RDM_EXPORT RDM_RETCODE EXTERNAL_FCN rdm_dbRepair (
2591  RDM_DB db,
2592  const RDM_TCHAR_T *optString
2594 );
2595 
2596 #if defined(__cplusplus)
2597 }
2598 #endif
RDM_RETCODE rdm_dbGetOptions(RDM_DB db, RDM_TCHAR_T *optString, size_t bytesIn, size_t *bytesOut)
Get RDM database specific options.
void(* RDM_ERROR_FCN)(RDM_DB, RDM_RETCODE, const RDM_TCHAR_T *, void *)
Definition: rdmtypes.h:270
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.
RDM_RETCODE() RDM_REBUILD_INDEX_REPORT_FCN(const char *table, const char *indexes, uint64_t current, uint64_t total)
Callback function signature to report status on an ID-index rebuild.
Definition: rdmtypes.h:139
struct RDM_TRANS_S * RDM_TRANS
Definition: rdmtypes.h:267
RDM_LOCK_STATUS
Enumeration for RDM table lock status.
Definition: rdmtypes.h:115
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.
struct RDM_CURSOR_S * RDM_CURSOR
Definition: rdmtypes.h:266
RDM_RETCODE rdm_dbSetErrorHandler(RDM_DB db, RDM_ERROR_FCN errorFunction, void *userData)
Replace default error reporting with a custom function.
RDM_RETCODE rdm_dbGetTFS(RDM_DB db, RDM_TFS *pTFS)
Get the RDM_TFS handle associated with a db.
Header for the native RDM Runtime types.
RDM_RETCODE rdm_dbStartSnapshot(RDM_DB db, const RDM_TABLE_ID *tableIds, uint32_t numTableIds, RDM_TRANS *pTrans)
Start a snapshot.
The RDM Partial Key data structure.
Definition: rdmtypes.h:33
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.
RDM_RETCODE rdm_dbImport(RDM_DB db, const RDM_TCHAR_T *optString)
Database import API.
RDM_RETCODE rdm_dbTriggersOn(RDM_DB db)
Enable use of triggers for an open database.
RDM_RETCODE rdm_dbRebuildIdIndex(RDM_DB db)
Rebuild the database ID Index.
RDM_RETCODE rdm_dbDeleteAllRowsFromTable(RDM_DB db, RDM_TABLE_ID tableId)
Remove all rows from a table.
RDM_RETCODE rdm_dbEnd(RDM_DB db)
End a transactional operation.
RDM_RETCODE rdm_dbClose(RDM_DB db)
Close the database associated with a database handle.
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.
The RDM Range Key data structure.
Definition: rdmtypes.h:78
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.
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.
RDM_RETCODE rdm_dbVacuum(RDM_DB db, const RDM_TCHAR_T *optString)
Database vacuum API.
uint32_t RDM_TABLE_ID
Definition: rdmtypes.h:27
struct RDM_TFS_S * RDM_TFS
RDM TFS Handle.
Definition: rdmtfstypes.h:21
RDM_RETCODE rdm_dbTriggersStatus(RDM_DB db, RDM_TRIGGERS_STATUS *pStat)
Check the triggers use status for a database.
RDM_RETCODE rdm_dbSetCatalogFromFile(RDM_DB db, const RDM_TCHAR_T *catfile)
Associate a catalog with an allocated database.
RDM_RETCODE rdm_dbPrecommit(RDM_DB db)
Precommit a transactional operation (Two-Phase Commit phase 1)
RDM_RETCODE rdm_dbSetCatalog(RDM_DB db, const RDM_TCHAR_T *catalog)
Associate a catalog with an allocated database.
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.
RDM_TRANS_STATUS
The RDM transaction status identifiers.
Definition: rdmtypes.h:94
RDM_RETCODE rdm_dbSetEncrypt(RDM_DB db, RDM_ENCRYPT enc)
Associate an encryption context with a database handle.
RDM_RETCODE rdm_dbLoadCatalogFromFile(RDM_DB db, const RDM_TCHAR_T *catfile)
Associate a catalog with an allocated database.
RDM_RETCODE rdm_dbAllocCursor(RDM_DB db, RDM_CURSOR *pCursor)
Allocate a cursor.
RDM_RETCODE rdm_dbSetOptions(RDM_DB db, const RDM_TCHAR_T *optString)
Set RDM options.
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.
RDM_RETCODE rdm_dbFlushIdIndex(RDM_DB db)
Flush the database ID Index.
RDM_RETCODE rdm_dbRepair(RDM_DB db, const RDM_TCHAR_T *optString)
RDM_RETCODE
RDM status and error return codes.
RDM_RETCODE rdm_dbTriggersOff(RDM_DB db)
Disable use of triggers for an open database.
RDM_RETCODE rdm_dbStartRead(RDM_DB db, const RDM_TABLE_ID *tableIds, uint32_t numTableIds, RDM_TRANS *pTrans)
Get read locks.
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.
RDM_OPEN_MODE
Enumeration for open modes.
Definition: rdmtypes.h:208
RDM_RETCODE rdm_dbFree(RDM_DB db)
Free a database handle.
RDM_RETCODE rdm_dbCompileCatalog(RDM_DB db, const RDM_TCHAR_T *schema)
Associate a schema with an allocated database.
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 th...
RDM_TRIGGERS_STATUS
Triggers status values.
Definition: rdmtypes.h:277
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.
The RDM R-tree Key data structure.
Definition: rdmtypes.h:62
RDM_RETCODE rdm_dbGetTFSType(RDM_DB db, TFS_TYPE *pTfsType)
Get the type of the RDM_TFS handle associated with a database.
RDM_RETCODE rdm_dbCompileCatalogFromFile(RDM_DB db, const RDM_TCHAR_T *schemafile)
Associate a catalog with an allocated database.
RDM_RETCODE rdm_dbCreateNewPackFile(RDM_DB db)
Create a new pack file.
uint32_t RDM_KEY_ID
Definition: rdmtypes.h:29
RDM_RETCODE rdm_dbEndRollback(RDM_DB db)
End and rollback a transactional operation.
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.
RDM_RETCODE rdm_dbGetMemoryUsage(RDM_DB db, uint64_t *systemCurr, uint64_t *systemMax, uint64_t *userCurr, uint64_t *userMax)
Get memory usage information for a database.
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.
RDM_RETCODE rdm_dbPersistInMemory(RDM_DB db)
Persist in-memory tables to disk.
RDM_RETCODE rdm_dbLoadCatalog(RDM_DB db, const RDM_TCHAR_T *catalog)
Associate a catalog with an allocated database.
struct RDM_DB_S * RDM_DB
Definition: rdmtypes.h:265
TFS_TYPE
Definition: rdmtfstypes.h:24
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.
RDM_RETCODE rdm_dbDeleteAllRowsFromDatabase(RDM_DB db)
Remove all rows from a database.
RDM_RETCODE rdm_dbClearCache(RDM_DB db)
Header for the Transactional File Server (TFS) types.
uint64_t RDM_ROWID_T
Definition: rdmrowidtypes.h:21
RDM_RETCODE rdm_dbExport(RDM_DB db, const RDM_TCHAR_T *optString)
Database export API.
#define RDM_TCHAR_T
Definition: psptypes.h:130
RDM_RETCODE rdm_dbAlterCatalog(RDM_DB db, const RDM_TCHAR_T *ddlStmt)
Process a schema DDL command.
Header for row ID types.
struct RDM_ENCRYPT_S * RDM_ENCRYPT
Definition: psptypes.h:73
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.
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 th...
RDM_RETCODE rdm_dbGetEncrypt(RDM_DB db, RDM_ENCRYPT *enc)
Get the encryption context associated with a database handle.
RDM_RETCODE rdm_dbEncrypt(RDM_DB db, RDM_ENCRYPT enc, const RDM_TCHAR_T *optString)
Encrypt a database.
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.
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.
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.
RDM_RETCODE rdm_dbOpen(RDM_DB db, const RDM_TCHAR_T *dbNameSpec, RDM_OPEN_MODE mode)
Open an existing RDM database using the specified database handle.
RDM_RETCODE rdm_dbGetTransactionStatus(RDM_DB db, RDM_TRANS_STATUS *status)
Get the transaction status for a database handle.