Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions src/sqlancer/citus/CitusBugs.java
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,9 @@ public final class CitusBugs {
// https://github.com/citusdata/citus/issues/6298
public static boolean bug6298 = true;

// https://github.com/citusdata/citus/issues/8553
public static boolean bug8553 = true;

private CitusBugs() {
}

Expand Down
9 changes: 9 additions & 0 deletions src/sqlancer/citus/gen/CitusTableGenerator.java
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
package sqlancer.citus.gen;

import sqlancer.citus.CitusBugs;
import sqlancer.common.query.SQLQueryAdapter;
import sqlancer.postgres.PostgresGlobalState;
import sqlancer.postgres.PostgresSchema;
Expand All @@ -20,4 +21,12 @@ public static SQLQueryAdapter generate(String tableName, PostgresSchema newSchem
return new CitusTableGenerator(tableName, newSchema, generateOnlyKnown, globalState).generate();
}

@Override
protected void generateInherits() {
if (CitusBugs.bug8553) {
return;
}
super.generateInherits();
}

}
2 changes: 1 addition & 1 deletion src/sqlancer/postgres/gen/PostgresTableGenerator.java
Original file line number Diff line number Diff line change
Expand Up @@ -206,7 +206,7 @@ private void generateUsing() {
sb.append(globalState.getRandomTableAccessMethod());
}

private void generateInherits() {
protected void generateInherits() {
if (Randomly.getBoolean() && !newSchema.getDatabaseTablesWithoutViews().isEmpty()) {
sb.append(" INHERITS(");
sb.append(newSchema.getDatabaseTablesRandomSubsetNotEmpty().stream().map(t -> t.getName())
Expand Down
Loading