0

我想在 knexFile 中指定一个自定义 schemaName,但该架构尚不存在。

const config = {
  client: "postgresql",
  connection: {
    database: DB_NAME,
    user: DB_USER,
    password: DB_PASSWORD,
    host: DB_HOST,
  },
   migrations: {
    schemaName: "custom_schema",
    tableName: "knex_migrations",
  },
};

但是当我运行迁移时,它说 custom_schema 不存在。在创建 knex_migration 和 knex_migration_lock 文件之前如何创建模式?

4

0 回答 0