接前面,看 SeqNext 函数:/* ---------------------------------------------------------------- * SeqNext * * This is a workhorse for ExecSeqScan * ---------------------------------------------------------------- */static TupleTableSlot *SeqNext(SeqScanState *node){ HeapTuple tuple; Heap...
转载 2013-05-31 17:30:00
146阅读
2评论
全表遍历预备知识《PostgreSQL 流程—查询》概述在《PostgreSQL 流程—查询》我们重点讨论了PostgreSQL的查询流程,提到全表遍历的操作主要有函数SeqNext来实现,本文将重点讨论SeqNext的流程。SeqNextSeqNext的代码比较短,我们直接来看代码:static TupleTableSlot * SeqNext(SeqScanState *node) { He
转载 2024-10-03 14:25:01
98阅读
在src/backend/executor/nodeSeqscan.c文件中的SeqNext函数会调用table_beginscan函数
原创 2022-12-31 08:24:00
177阅读
接前面,看被SeqNext所调用的heap_getnext:HeapTupleheap_getnext(HeapScanDesc scan, ScanDirection direction){ /* Note: no locking manipulations needed */ HEAPDEBUG_1; /* heap_getnext( info ) */ if (scan->rs_pageatatime) heapgettup_pagemode(scan, direction,scan->rs_nkeys, scan->rs_k...
转载 2013-06-03 10:13:00
51阅读
2评论