Skip to content
Merged
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
4 changes: 2 additions & 2 deletions src/database/table.ts
Original file line number Diff line number Diff line change
Expand Up @@ -70,8 +70,8 @@ export default class Table {
}

static async isPartitioned(schema: string, name: string): Promise<boolean> {
const sql = `select table_name, partitioned_table from qsys2.sysfiles where table_schema = ? and table_name = ? and partitioned_table is not null and partitioned_table = 'YES'`;
const parameters = [schema, name];
const sql = `select table_name, partitioned_table from qsys2.sysfiles where ((table_schema = ? and table_name = ?) or (system_table_schema = ? and system_table_name = ?)) and partitioned_table is not null and partitioned_table = 'YES'`;
const parameters = [schema, name, schema, name];

const result = await JobManager.runSQL(sql, {parameters});
return result.length > 0;
Expand Down
Loading