Uploaded image for project: 'DdlUtils'
  1. DdlUtils
  2. DDLUTILS-221

ddlutils tries to drop an index in postgres which is really a unique constraint

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Open
    • Major
    • Resolution: Unresolved
    • 1.0
    • None
    • Core - PostgreSql
    • None

    Description

      I have a unique constraint on a col, and ddltuils tries to drop it like its only an index, which gives an error:

      [sql] Failed to execute: DROP INDEX fields_name_type_unq

      BUILD FAILED
      C:\mchyzer\isc\dev\grouper-qs-1.2.0\grouper\build.xml:769: org.postgresql.util.PSQLException: ERROR: cannot drop index fields_name_type_unq because constraint fields_name_type_unq on table grouper_fields requires it

      The solution would be to look at db metadata, see that it is a constraint, drop the constraint, then drop the index (if it isnt dropped by dropping the constraint)

      Thanks,
      chris

      Attachments

        Activity

          People

            tomdz Thomas Dudziak
            mchyzer Chris Hyzer
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated: