normalize name for oracle constraint names?

Issue #3276 resolved
Mike Bayer repo owner created an issue

during reflection, we are not normalizing names for all constraint objects. looks like we are doing the name for primary key and index but not get_foreign_keys().

Comments (6)

  1. Mike Bayer reporter
    • changed milestone to 1.1

    not sure if this one needs to go in just yet. we don't really get reports of this being a problem as of yet, however it might become so as alembic use continues to grow and now that the FK feature is added.

  2. Mike Bayer reporter
    • changed milestone to 1.2

    pushing this out, currently alembic isn't comparing constraint names in any case for autogen. the issue would be that autogen creates the "downgrade" using all uppercase names which would normalize to quoted uppercase and cause problems. oddly, nobody has reported that yet. so would need to confirm.

  3. Mike Bayer reporter

    also there seems to be no test coverage for the actual name. going to see if i can do a gerrit right now for this

  4. Mike Bayer reporter

    Normalize Oracle reflected FK constraint name

    Oracle reflection now "normalizes" the name given to a foreign key constraint, that is, returns it as all lower case for a case insensitive name. This was already the behavior for indexes and primary key constraints as well as all table and column names. This will allow Alembic autogenerate scripts to compare and render foreign key constraint names correctly when initially specified as case insensitive.

    Change-Id: Ibb34ec6ce7cb244d1c4ae9d44ce2d37d37227e69 Fixes: #3276

    → <<cset 6b0e12fd6f50>>

  5. Log in to comment