implemented prepared statement for postgres and sqlite

This commit is contained in:
2023-12-09 11:08:03 +01:00
parent 8ba70cc79e
commit da423ea8bb
59 changed files with 1769 additions and 314 deletions
+14 -6
View File
@@ -1,11 +1,19 @@
#include "sqlite_dialect.hpp"
[[maybe_unused]] const matador::sql::dialect* get_dialect() {
#include "matador/sql/dialect_builder.hpp"
[[maybe_unused]] const matador::sql::dialect *get_dialect()
{
using namespace matador::sql;
const static dialect d{{
{ dialect::token_t::BEGIN, "BEGIN TRANSACTION"},
{ dialect::token_t::COMMIT, "COMMIT TRANSACTION"},
{ dialect::token_t::ROLLBACK, "ROLLBACK TRANSACTION"}
}};
const static dialect d = dialect_builder::builder()
.create()
.with_token_replace_map({
{dialect::token_t::BEGIN, "BEGIN TRANSACTION"},
{dialect::token_t::COMMIT, "COMMIT TRANSACTION"},
{dialect::token_t::ROLLBACK, "ROLLBACK TRANSACTION"}
})
.with_default_schema_name("main")
.build();
return &d;
}