-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathdistributed_delete.hpp
More file actions
46 lines (35 loc) · 1.47 KB
/
Copy pathdistributed_delete.hpp
File metadata and controls
46 lines (35 loc) · 1.47 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
#pragma once
#include "duckdb/catalog/catalog_entry/table_catalog_entry.hpp"
#include "duckdb/execution/physical_operator.hpp"
namespace duckdb {
// Physical operator that intercepts DELETE and sends to distributed server.
class PhysicalDistributedDelete : public PhysicalOperator {
public:
PhysicalDistributedDelete(PhysicalPlan &physical_plan, vector<LogicalType> types, TableCatalogEntry &table_p,
PhysicalOperator &child_operator, idx_t row_id_index_p, idx_t estimated_cardinality,
bool return_chunk_p);
TableCatalogEntry &table;
PhysicalOperator &child;
idx_t row_id_index;
bool return_chunk;
public:
// Sink interface.
unique_ptr<GlobalSinkState> GetGlobalSinkState(ClientContext &context) const override;
unique_ptr<LocalSinkState> GetLocalSinkState(ExecutionContext &context) const override;
SinkResultType Sink(ExecutionContext &context, DataChunk &chunk, OperatorSinkInput &input) const override;
SinkFinalizeType Finalize(Pipeline &pipeline, Event &event, ClientContext &context,
OperatorSinkFinalizeInput &input) const override;
bool IsSink() const override {
return true;
}
bool ParallelSink() const override {
return false;
}
// Source interface.
SourceResultType GetDataInternal(ExecutionContext &context, DataChunk &chunk,
OperatorSourceInput &input) const override;
bool IsSource() const override {
return true;
}
};
} // namespace duckdb