Joins two registered tables on a key column and outputs a chosen subset of fields from each side, computed in memory. Built by JoinTableBuilder and registered against a query or report definition (for example through Queries.addJoinTable or ControllerMappingList.addJoinTable), then looked up by id like any other Table when a report runs. The left table is read in full; the right table is paged and its rows cached by join value until a match for each left row is found.

Implements: Table


Properties

PropertyReturnsDescription
descriptionStringThe description configured on the JoinTableBuilder for this join table.
headersList<String>Column headers for the joined output, one per configured output field, in the order the fields were added to the builder.
tableIdStringThe id this join table is registered and looked up under, as set on the JoinTableBuilder.

Inherited from Table

Methods

getRows(int start, Integer maxRows)

Returns: RowsResult

Reads a page of rows starting at the given row, discarding any progress status. Delegates to the three argument overload with a status callback that does nothing.

ParameterDescription
startthe zero based index of the first row to return
maxRowsthe maximum number of rows to return, or null for no limit

getRows(int start, Integer maxRows, Consumer<String> status, Map<String,Object> extraParams)

Returns: RowsResult

Reads a page of rows, optionally taking extra parameters that a specific table implementation can use to filter its results. The default implementation ignores extraParams and reads from row zero rather than the given start; implementations that use extraParams override this method directly.

ParameterDescription
startthe zero based index of the first row to return; not used by the default implementation
maxRowsthe maximum number of rows to return, or null for no limit
statuscallback invoked with progress messages while the rows are being read
extraParamsimplementation specific filter parameters; not used by the default implementation

supportsPagination()

Returns: boolean

Whether this table supports paged reads via the start and maxRows parameters of getRows. A table that returns false always returns its full result set regardless of the paging parameters supplied.


Methods

getHeaders()

Returns: List<String>

Column headers for the joined output, one per configured output field, in the order the fields were added to the builder.

getTableId()

Returns: String

The id this join table is registered and looked up under, as set on the JoinTableBuilder.

getDescription()

Returns: String

The description configured on the JoinTableBuilder for this join table.

getRows(int start, Integer maxRows, Consumer<String> status)

Returns: RowsResult

Reads a page of rows from the left table starting at start, and for each left row finds the matching right table row (paging and caching the right table by join value as needed), then assembles the output cells from the configured fields. Throws a RuntimeException if the left table, or a configured right table, cannot be found.

ParameterDescription
startthe zero based index of the first left table row to read
maxRowsthe maximum number of left table rows to read, or null for no limit
statuscallback invoked with progress messages while the left and right tables are being read
To get full access to the Kademi Hub existing customers can login here, or new customers can register here.