/** * @file mix_cc/sql/delete_from.h * @brief 删除 语句 * @author Cat (null.null.null@qq.com) * @version 0.1 * @date 2021-09-17 * * Copyright: Baosight Co. Ltd. * DO NOT COPY/USE WITHOUT PERMISSION * */ #pragma once #include #include #include #include namespace mix_cc { namespace sql { template struct delete_from_t : public prev_statement_t, public statement_t { static constexpr auto s_text = op::cmd_t::delete_from; constexpr explicit delete_from_t(Tab table) : prev_statement_t(), table_(table) {} template constexpr auto where(Conditions... conditions) { return where_t(*this, conditions...); } constexpr auto get_command() { return s_text + " "_s + table_.get_table_name(); } public: Tab table_; }; template auto delete_from(Tab table) { return delete_from_t(table); } } // namespace sql } // namespace mix_cc