MCPcopy Create free account
hub / github.com/LadybugDB/ladybug / lookupMultiple

Method lookupMultiple

src/storage/table/node_group.cpp:305–320  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

303}
304
305bool NodeGroup::lookupMultiple(const UniqLock& lock, const Transaction* transaction,
306 const TableScanState& state) const {
307 idx_t numTuplesFound = 0;
308 for (auto i = 0u; i < state.rowIdxVector->state->getSelVector().getSelSize(); i++) {
309 auto& nodeGroupScanState = *state.nodeGroupScanState;
310 const auto pos = state.rowIdxVector->state->getSelVector().getSelectedPositions()[i];
311 DASSERT(!state.rowIdxVector->isNull(pos));
312 const auto rowIdx = state.rowIdxVector->getValue<row_idx_t>(pos);
313 const ChunkedNodeGroup* chunkedGroupToScan = findChunkedGroupFromRowIdx(lock, rowIdx);
314 DASSERT(chunkedGroupToScan);
315 const auto rowIdxInChunkedGroup = rowIdx - chunkedGroupToScan->getStartRowIdx();
316 numTuplesFound += chunkedGroupToScan->lookup(transaction, state, nodeGroupScanState,
317 rowIdxInChunkedGroup, i);
318 }
319 return numTuplesFound == state.rowIdxVector->state->getSelVector().getSelSize();
320}
321
322bool NodeGroup::lookup(const Transaction* transaction, const TableScanState& state,
323 sel_t posInSel) const {

Callers 3

lookupRangeMethod · 0.45
scanMethod · 0.45
findMatchingRowMethod · 0.45

Calls 6

getSelSizeMethod · 0.80
getStartRowIdxMethod · 0.80
getSelectedPositionsMethod · 0.45
isNullMethod · 0.45
lookupMethod · 0.45
lockMethod · 0.45

Tested by

no test coverage detected