summaryrefslogtreecommitdiff
path: root/src/database/table.hpp
diff options
context:
space:
mode:
authorlouiz’ <louiz@louiz.org>2018-09-03 22:26:57 +0200
committerlouiz’ <louiz@louiz.org>2018-09-03 22:26:57 +0200
commit193302b0de20df6adc090eaeaa84cfd286be724a (patch)
treeb9e0e0f75b5cd74911a42a7fcd0f1477971391ff /src/database/table.hpp
parent56651cb5c29cc50ddf3c62c37167fa0b9389bfde (diff)
parent28acbed948e1c281f9de6132164e42d0ed20c32f (diff)
downloadbiboumi-193302b0de20df6adc090eaeaa84cfd286be724a.tar.gz
biboumi-193302b0de20df6adc090eaeaa84cfd286be724a.tar.bz2
biboumi-193302b0de20df6adc090eaeaa84cfd286be724a.tar.xz
biboumi-193302b0de20df6adc090eaeaa84cfd286be724a.zip
Merge branch 'master' into debian
Diffstat (limited to 'src/database/table.hpp')
-rw-r--r--src/database/table.hpp11
1 files changed, 6 insertions, 5 deletions
diff --git a/src/database/table.hpp b/src/database/table.hpp
index 680e7cc..0b8bfc0 100644
--- a/src/database/table.hpp
+++ b/src/database/table.hpp
@@ -2,7 +2,7 @@
#include <database/engine.hpp>
-#include <database/select_query.hpp>
+#include <database/delete_query.hpp>
#include <database/row.hpp>
#include <algorithm>
@@ -79,10 +79,10 @@ class Table
return {this->name};
}
- auto select()
+ auto del()
{
- SelectQuery<T...> select(this->name);
- return select;
+ DeleteQuery query(this->name);
+ return query;
}
const std::string& get_name() const
@@ -90,6 +90,8 @@ class Table
return this->name;
}
+ const std::string name;
+
private:
template <std::size_t N=0>
@@ -124,5 +126,4 @@ class Table
add_column_create(DatabaseEngine&, std::string&)
{ }
- const std::string name;
};