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

Add multiple schema support

Add voteWatch issue
    XMLWordPrintableJSON

Details

    Description

      As mentioned in issue 116 there was no support for multiple schemas.
      This patch adds initial support against the latest svn head (603834).

      Features added in this patch include:

      • support for schema definition in xml schema definition document
      • ability to create / drop multiple schemas in a single database (yes, even from ant)
      • support for object creation / removal in separate schemas (tables, constraints, sequences, etc...)
      • support for insert / update / delete operations for separate schemas
      • support for altering model with multiple schemas

      This multiple schema support was added as a boolean attribute to the PlatformInfo and is currently only "enabled" for the PostgreSQL platform implementation.

      If you're interested in "enabling" this feature for another platform you should also override the "createSchemas" and "dropSchemas" methods in the specific platform's SqlBuilder implementation.

      Also added in this patch:

      • ObjectStor class which can serialize a java object to a byte array and un-serialize an existing byte array back to a java object

      This class is useful when the platform isn't able to deal directly with the JAVA_OBJECT type.
      I used this in setObject method of the PostgreSqlPlatform class when the type is a JAVA_OBJECT because the PostgreSQL jdbc driver is unable to deal directly with java objects (it stores the serialized object instead).

      Attachments

        1. ddlutils-multischema.patch
          211 kB
          Jon Keys

        Activity

          People

            tomdz Thomas Dudziak
            jkeys Jon Keys

            Dates

              Created:
              Updated:

              Slack

                Issue deployment