-
Notifications
You must be signed in to change notification settings - Fork 120
Closed
Description
I run cakephp 5 with a postgres DB (postgresSQL 18.1).
I added this new column to a table:

I generated a new migration file with the bake tool.
bin/cake bake migration_diff ModPmOrderPositionsAddCPosNr
The generated migation has this up function:
public function up(): void
{
$this->table('mod_pm_order_positions')
->addColumn('cpos_nr', 'string', [
'after' => 'is_optional',
'collate' => null,
'comment' => 'Nummerierung für die Anzeige',
'default' => null,
'length' => 30,
'null' => true,
])
->update();
}
When I try to use the migration
bin/cake migrations migrate
I get the following error: "collate" is not a valid column option."

If I manually delete the collate option from the migration, it works fine.
Currenlty I would have to manually delete that 'collate' => null from each autogenerated migration.
Could you fix the bake script, so the generated migration does not throw an error?
Metadata
Metadata
Assignees
Labels
No labels