| 1 | #include "duckdb/planner/expression_binder/update_binder.hpp" |
|---|---|
| 2 | |
| 3 | namespace duckdb { |
| 4 | |
| 5 | UpdateBinder::UpdateBinder(Binder &binder, ClientContext &context) : ExpressionBinder(binder, context) { |
| 6 | } |
| 7 | |
| 8 | BindResult UpdateBinder::BindExpression(unique_ptr<ParsedExpression> &expr_ptr, idx_t depth, bool root_expression) { |
| 9 | auto &expr = *expr_ptr; |
| 10 | switch (expr.expression_class) { |
| 11 | case ExpressionClass::WINDOW: |
| 12 | return BindResult("window functions are not allowed in UPDATE"); |
| 13 | default: |
| 14 | return ExpressionBinder::BindExpression(expr_ptr, depth); |
| 15 | } |
| 16 | } |
| 17 | |
| 18 | string UpdateBinder::UnsupportedAggregateMessage() { |
| 19 | return "aggregate functions are not allowed in UPDATE"; |
| 20 | } |
| 21 | |
| 22 | } // namespace duckdb |
| 23 |