Skip to content

Commit e0b080f

Browse files
committed
RuntimeInsert node
1 parent e526274 commit e0b080f

File tree

2 files changed

+48
-0
lines changed

2 files changed

+48
-0
lines changed

src/runtime_insert.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
#include "runtime_insert.h"

src/runtime_insert.h

Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
#ifndef RUNTIME_INSERT_H
2+
#define RUNTIME_INSERT_H
3+
4+
#include "postgres.h"
5+
#include "optimizer/paths.h"
6+
#include "optimizer/pathnode.h"
7+
8+
#include "pathman.h"
9+
#include "nodes_common.h"
10+
11+
12+
typedef struct
13+
{
14+
CustomPath cpath;
15+
} RuntimeInsertPath;
16+
17+
typedef struct
18+
{
19+
CustomScanState css;
20+
} RuntimeInsertState;
21+
22+
extern bool pg_pathman_enable_runtime_insert;
23+
24+
extern CustomScanMethods runtime_insert_plan_methods;
25+
extern CustomExecMethods runtime_insert_exec_methods;
26+
27+
Path * create_runtimeinsert_path(PlannerInfo *root, AppendPath *inner_append,
28+
ParamPathInfo *param_info,
29+
double sel);
30+
31+
Plan * create_runtimeinsert_plan(PlannerInfo *root, RelOptInfo *rel,
32+
CustomPath *best_path, List *tlist,
33+
List *clauses, List *custom_plans);
34+
35+
Node * runtimeinsert_create_scan_state(CustomScan *node);
36+
37+
void runtimeinsert_begin(CustomScanState *node, EState *estate, int eflags);
38+
39+
TupleTableSlot * runtimeappend_exec(CustomScanState *node);
40+
41+
void runtimeinsert_end(CustomScanState *node);
42+
43+
void runtimeinsert_rescan(CustomScanState *node);
44+
45+
void runtimeinsert_explain(CustomScanState *node, List *ancestors, ExplainState *es);
46+
47+
#endif

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy