PageDataIndex

The scan index allows to access a row by key. It can be used to iterate over all rows of a table. Each regular table has one such object, even if no primary key or indexes are defined.

Methods
void add(Session session, Row row)
void add(Session session, Row row)
boolean canGetFirstOrLast()
boolean canGetFirstOrLast()
void checkRename()
void checkRename()
void close(Session session)
void close(Session session)
void commit(int operation, Row row)
void commit(int operation, Row row)
Cursor find(Session session, SearchRow first, SearchRow last)
Cursor find(Session session, SearchRow first, SearchRow last)
Cursor find(Session session, long first, long last, boolean multiVersion)
Search for a specific row or a set of rows.
Cursor find(Session session, long first, long last, boolean multiVersion)
Search for a specific row or a set of rows.
Parameters:
session - the session
first - the key of the first row
last - the key of the last row
multiVersion - if mvcc should be used
Returns:
the cursor
Cursor findFirstOrLast(Session session, boolean first)
Cursor findFirstOrLast(Session session, boolean first)
int getColumnIndex(Column col)
int getColumnIndex(Column col)
double getCost(Session session, int[] masks, TableFilter[] filters, int filter, SortOrder sortOrder, HashSet allColumnsSet)
double getCost(Session session, int[] masks, TableFilter[] filters, int filter, SortOrder sortOrder, HashSet allColumnsSet)
String getCreateSQL()
String getCreateSQL()
Iterator getDelta()
Iterator getDelta()
long getDiskSpaceUsed()
long getDiskSpaceUsed()
DbException getDuplicateKeyException(String key)
DbException getDuplicateKeyException(String key)
long getKey(SearchRow row, long ifEmpty, long ifNull)
Get the key from the row.
long getKey(SearchRow row, long ifEmpty, long ifNull)
Get the key from the row.
Parameters:
row - the row
ifEmpty - the value to use if the row is empty
ifNull - the value to use if the column is NULL
Returns:
the key
long getLastKey()
long getLastKey()
int getMainIndexColumn()
int getMainIndexColumn()
int getMemoryPerPage()
int getMemoryPerPage()
DbException getNewDuplicateKeyException()
DbException getNewDuplicateKeyException()
PageData getPage(int id, int parent)
Read the given page.
PageData getPage(int id, int parent)
Read the given page.
Parameters:
id - the page id
parent - the parent, or -1 if unknown
Returns:
the page
PageDataOverflow getPageOverflow(int id)
Read an overflow page page.
PageDataOverflow getPageOverflow(int id)
Read an overflow page page.
Parameters:
id - the page id
Returns:
the page
PageStore getPageStore()
PageStore getPageStore()
String getPlanSQL()
String getPlanSQL()
Row getRow(Session session, long key)
Row getRow(Session session, long key)
long getRowCount(Session session)
long getRowCount(Session session)
long getRowCountApproximation()
long getRowCountApproximation()
Row getRowWithKey(long key)
Get the row with the given key.
Row getRowWithKey(long key)
Get the row with the given key.
Parameters:
key - the key
Returns:
the row
boolean isFirstColumn(Column column)
boolean isFirstColumn(Column column)
boolean isRowIdIndex()
boolean isRowIdIndex()
void memoryChange(int x)
The memory usage of a page was changed.
void memoryChange(int x)
The memory usage of a page was changed. The new value is used to adopt the average estimated memory size of a page.
Parameters:
x - the new memory size
boolean needRebuild()
boolean needRebuild()
void remove(Session session, Row row)
void remove(Session session, Row row)
void remove(Session session)
void remove(Session session)
void setMainIndexColumn(int mainIndexColumn)
void setMainIndexColumn(int mainIndexColumn)
void setRootPageId(Session session, int newPos)
The root page has changed.
void setRootPageId(Session session, int newPos)
The root page has changed.
Parameters:
session - the session
newPos - the new position
String toString()
String toString()
void truncate(Session session)
void truncate(Session session)
void writeRowCount()
void writeRowCount()