DdlUtils
  1. DdlUtils
  2. DDLUTILS-135

mergeWith in Database needs to handle existing tables correctly

    Details

    • Type: Bug Bug
    • Status: Open
    • Priority: Major Major
    • Resolution: Unresolved
    • Affects Version/s: 1.0
    • Fix Version/s: 1.3
    • Labels:
      None
    • Environment:
      MySQL

      Description

      mergeWith in Database.java throws a ModelException if the target database already contains a table described in the source (additional) model.
      The correct behavior would compare the existing table and the new description and add columns, keys and indexes to the target if necessary (note that for all practical purposes existing columns/indexes etc. should NOT be removed)

        Activity

        Hide
        Hajo Birthelmer added a comment -

        The attached patch contains a table-merge logic that allows two tables to be compared for columns,foreign keys and indexes and adds missing elements to the target.

        Show
        Hajo Birthelmer added a comment - The attached patch contains a table-merge logic that allows two tables to be compared for columns,foreign keys and indexes and adds missing elements to the target.

          People

          • Assignee:
            Thomas Dudziak
            Reporter:
            Hajo Birthelmer
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:

              Development