Functions | |
RDM_RETCODE | rdm_cursorComparePosition (RDM_CURSOR cursorPrimary, RDM_CURSOR cursorSecondary, RDM_CURSOR_COMPARE *comparison) |
compare the position of a cursor relative to another cursor More... | |
RDM_RETCODE | rdm_cursorGetStatus (RDM_CURSOR cursor, RDM_CURSOR_STATUS *position) |
Check a cursor for special conditions. More... | |
RDM_RETCODE | rdm_cursorIsAfterLast (RDM_CURSOR cursor, RDM_BOOL_T *isAfterLast) |
Check to see if a cursor is positioned after the last row in a collection. More... | |
RDM_RETCODE | rdm_cursorIsBeforeFirst (RDM_CURSOR cursor, RDM_BOOL_T *isBeforeFirst) |
Check to see if a cursor is positioned before the first row in a collection. More... | |
API for comparing core cursor positions. All the functions here are located in RDM DB Engine Library. Linker option:
-lrdmrdm
See RDM Cursor APIs for a more detailed description of a cursor.
RDM_RETCODE rdm_cursorComparePosition | ( | RDM_CURSOR | cursorPrimary, |
RDM_CURSOR | cursorSecondary, | ||
RDM_CURSOR_COMPARE * | comparison | ||
) |
#include <rdmcursorapi.h>
compare the position of a cursor relative to another cursor
This function compares the current position of cursorPrimary relative to cursorSecondary.
If the cursor types are not the same the current row of the secondary will be used and then converted to a position in the cursor type of cursorPrimary. If the current row of the secondary is not a valid cursor position in the primary an error will be returned.
This means:
sOKAY | Normal, successful return. |
eNOTINCURSOR | The row is not in the cursor. |
[in] | cursorPrimary | The cursor whose current row is being checked relative to cursorSecondary |
[in] | cursorSecondary | The cursor whose current row is being checked against |
[in] | comparison | A pointer to the returned comparison result value |
RDM_RETCODE rdm_cursorGetStatus | ( | RDM_CURSOR | cursor, |
RDM_CURSOR_STATUS * | position | ||
) |
#include <rdmcursorapi.h>
Check a cursor for special conditions.
This function will return information about an RDM_CURSOR's position.
As you navigate (using any of the rdm_cursorMove* functions) the cursor will typically be in any of these states: CURSOR_BEFORE_FIRST; CURSOR_AT_ROW; CURSOR_BETWEEN; or, CURSOR_BEFORE_FIRST. Changes to the row through this cursor or any other cursor may put the cursor in some other state.
sOKAY | Normal, successful return. |
eNOSTARTREAD | A read operation was attempted when no rdm_dbStartSnapshot(), rdm_dbStartRead(), or rdm_dbStartUpdate() is active. |
eNOTLOCKED | Attempt to access a table for reading or update without proper locks. |
eDBNOTOPEN | Database not open. |
[in] | cursor | The cursor whose position is being checked |
[out] | position | The check position result value |
RDM_RETCODE rdm_cursorIsAfterLast | ( | RDM_CURSOR | cursor, |
RDM_BOOL_T * | isAfterLast | ||
) |
#include <rdmcursorapi.h>
Check to see if a cursor is positioned after the last row in a collection.
This function will set isAfterLast to RDM_TRUE if the cursor is positioned after the last row in the cursor collection.
sOKAY | Normal, successful return. |
eDBNOTOPEN | Database not open. |
[in] | cursor | The cursor whose position is being checked |
[out] | isAfterLast | A pointer to the returned condition |
RDM_RETCODE rdm_cursorIsBeforeFirst | ( | RDM_CURSOR | cursor, |
RDM_BOOL_T * | isBeforeFirst | ||
) |
#include <rdmcursorapi.h>
Check to see if a cursor is positioned before the first row in a collection.
This function will set isBeforeFirst to RDM_TRUE if the cursor is positioned before the first row in the cursor collection.
sOKAY | Normal, successful return. |
eDBNOTOPEN | Database not open. |
[in] | cursor | The cursor whose position is being checked |
[out] | isBeforeFirst | A pointer to the returned condition |