| 1 | #include "duckdb/execution/operator/scan/physical_index_scan.hpp" | 
|---|---|
| 2 | #include "duckdb/execution/physical_plan_generator.hpp" | 
| 3 | |
| 4 | #include "duckdb/planner/operator/logical_index_scan.hpp" | 
| 5 | |
| 6 | using namespace duckdb; | 
| 7 | using namespace std; | 
| 8 | |
| 9 | unique_ptr<PhysicalOperator> PhysicalPlanGenerator::CreatePlan(LogicalIndexScan &op) { | 
| 10 | unique_ptr<PhysicalOperator> plan; | 
| 11 | auto node = make_unique<PhysicalIndexScan>(op, op.tableref, op.table, op.index, op.column_ids); | 
| 12 | if (op.equal_index) { | 
| 13 | node->equal_value = op.equal_value; | 
| 14 | node->equal_index = true; | 
| 15 | } | 
| 16 | if (op.low_index) { | 
| 17 | node->low_value = op.low_value; | 
| 18 | node->low_index = true; | 
| 19 | node->low_expression_type = op.low_expression_type; | 
| 20 | } | 
| 21 | if (op.high_index) { | 
| 22 | node->high_value = op.high_value; | 
| 23 | node->high_index = true; | 
| 24 | node->high_expression_type = op.high_expression_type; | 
| 25 | } | 
| 26 | plan = move(node); | 
| 27 | return plan; | 
| 28 | } | 
| 29 | 
