/** * Returns selected columns from the first row in the "to" table based on * the given columns in the "from" table if any, {@code null} if there is no * matching row. * * @param fromRow row from the "from" table (which must include the relevant * columns for this join relationship) * @param columnNames desired columns in the from table row */ public Row findFirstRow(Map<String,?> fromRow, Collection<String> columnNames) throws IOException { return (hasRows(fromRow) ? _toCursor.getCurrentRow(columnNames) : null); }
@Override public TableInfo lookupTable(String tableName) throws IOException { if(findRow(_tableParentId, tableName) == null) { return null; } Row row = _systemCatalogCursor.getCurrentRow( SYSTEM_CATALOG_TABLE_DETAIL_COLUMNS); Integer pageNumber = row.getInt(CAT_COL_ID); String realName = row.getString(CAT_COL_NAME); int flags = row.getInt(CAT_COL_FLAGS); Short type = row.getShort(CAT_COL_TYPE); if(!isTableType(type)) { return null; } String linkedDbName = row.getString(CAT_COL_DATABASE); String linkedTableName = row.getString(CAT_COL_FOREIGN_NAME); return createTableInfo(realName, pageNumber, flags, type, linkedDbName, linkedTableName); }
complexTypeId)); Row cColRow = cursor.getCurrentRow(); int tableId = cColRow.getInt(COL_TABLE_ID); if(tableId != column.getTable().getTableDefPageNumber()) {
rowPattern.put("Type", 3); if (crsr.findFirstRow(rowPattern)) { Integer relationshipsId = crsr.getCurrentRow().getInt("Id"); r = crsr.findRowByEntry(relationshipsId, relationshipName); if (r != null) {