symfony-cmf / routing-bundle

Symfony bundle to provide the CMF chain router to handle multiple routers, and the dynamic router to load routes from a database or other sources.
160 stars 78 forks source link

Fix create unique index for Oracle DB #467

Closed FaritSlv closed 3 years ago

FaritSlv commented 3 years ago
Q A
Branch? 2.5.1
Bug fix? no
New feature? no
BC breaks? no
Deprecations? no
Fixed tickets
License MIT
Doc PR
FaritSlv commented 3 years ago

@dbu hello.

This fix creates the correct index for any ORM database.

The point is that there is no such problem in MySQL (Maria DB), that is, it creates a unique index on a column and separately (alias) an index on the same column. In OracleDB it is impossible to create 2 different indexes on the same column. An error will occur that the index has already been created.

MySQL: image

Correct create index: image

dbu commented 3 years ago

ah, so we even ended up with a duplicated index in mysql? then that fix benefits even those using mysql or postgres.

can you please rebase the branch so that we can see the CI working?

and can you please add a note in the CHANGELOG.md file that quickly explains what changed and why? (it might be that people upgrading will see a doctrine migration for example, to cleanup the duplicated index)

FaritSlv commented 3 years ago

@dbu Ok. I will close this PR, create a new one with a link to this one.

dbu commented 3 years ago

that is always the last resort. i will be travelling in the next days, will look into it end of this week.

FaritSlv commented 3 years ago

@dbu ready PR