session insert builder progress

This commit is contained in:
Sascha Kühl
2025-02-28 16:12:52 +01:00
parent 261f9fd6cb
commit 6ec5011e21
5 changed files with 85 additions and 45 deletions
+9 -1
View File
@@ -7,10 +7,12 @@ namespace matador::sql {
column_generator::column_generator(std::vector<column> &column_infos,
const object::schema &scm,
const std::string &table_name,
bool force_lazy)
const bool force_lazy,
const bool has_many_to_many)
: column_infos_(column_infos)
, table_schema_(scm)
, force_lazy_(force_lazy)
, has_many_to_many_(has_many_to_many)
{
table_name_stack_.push(table_name);
seen_tables.insert(table_name);
@@ -18,11 +20,17 @@ column_generator::column_generator(std::vector<column> &column_infos,
void column_generator::on_primary_key(const char *id, std::string &, size_t)
{
if (has_many_to_many_) {
return;
}
push(id);
}
void column_generator::on_revision(const char *id, unsigned long long int &)
{
if (has_many_to_many_) {
return;
}
push(id);
}