types/sequelize

QueryInterface missing Schema Name

nodejayes opened this issue · 1 comments

Hi,

The first parameter of the bulkInsert function is the table name as string. However, this can also be an object with the schema and Table Name properties if the schema has to be defined.

I would suggest defining a new interface that looks like this:

export interface TableDefinition {
    schema: string;
    tableName: string;
}

Then the first parameter of the bulkInsert function can be turned into a Union Type => string | TableDefinition.

I suspect this affects all functions that have the tableName as parameter.

look this

A year later this is still a problem. @nodejayes @goenning