1//===----------------------------------------------------------------------===//
2// DuckDB
3//
4// duckdb/parser/statement/delete_statement.hpp
5//
6//
7//===----------------------------------------------------------------------===//
8
9#pragma once
10
11#include "duckdb/parser/parsed_expression.hpp"
12#include "duckdb/parser/sql_statement.hpp"
13#include "duckdb/parser/tableref.hpp"
14#include "duckdb/parser/query_node.hpp"
15
16namespace duckdb {
17
18class DeleteStatement : public SQLStatement {
19public:
20 static constexpr const StatementType TYPE = StatementType::DELETE_STATEMENT;
21
22public:
23 DeleteStatement();
24
25 unique_ptr<ParsedExpression> condition;
26 unique_ptr<TableRef> table;
27 vector<unique_ptr<TableRef>> using_clauses;
28 vector<unique_ptr<ParsedExpression>> returning_list;
29 //! CTEs
30 CommonTableExpressionMap cte_map;
31
32protected:
33 DeleteStatement(const DeleteStatement &other);
34
35public:
36 string ToString() const override;
37 unique_ptr<SQLStatement> Copy() const override;
38};
39
40} // namespace duckdb
41