sqoop-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From gwens...@apache.org
Subject sqoop git commit: SQOOP-1994: Sqoop2: Use common repository constants
Date Sat, 07 Feb 2015 01:19:27 GMT
Repository: sqoop
Updated Branches:
  refs/heads/sqoop2 2a4af53b0 -> cfe273400


SQOOP-1994: Sqoop2: Use common repository constants

(Abraham Elmahrek via Gwen Shapira)


Project: http://git-wip-us.apache.org/repos/asf/sqoop/repo
Commit: http://git-wip-us.apache.org/repos/asf/sqoop/commit/cfe27340
Tree: http://git-wip-us.apache.org/repos/asf/sqoop/tree/cfe27340
Diff: http://git-wip-us.apache.org/repos/asf/sqoop/diff/cfe27340

Branch: refs/heads/sqoop2
Commit: cfe27340039293a99f05b58c0b8801da51c98205
Parents: 2a4af53
Author: Gwen Shapira <cshapi@gmail.com>
Authored: Fri Feb 6 17:18:23 2015 -0800
Committer: Gwen Shapira <cshapi@gmail.com>
Committed: Fri Feb 6 17:18:23 2015 -0800

----------------------------------------------------------------------
 .../common/CommonRepositorySchemaConstants.java | 117 ++++--
 .../derby/DerbyRepositoryHandler.java           |   3 +-
 .../repository/derby/DerbySchemaConstants.java  | 181 ----------
 .../postgresql/PostgresqlRepositoryHandler.java |   5 +-
 .../postgresql/PostgresqlSchemaConstants.java   | 358 -------------------
 .../postgresql/PostgresqlSchemaCreateQuery.java | 308 ++++++++--------
 .../postgresql/PostgresqlSchemaQuery.java       |  23 +-
 7 files changed, 256 insertions(+), 739 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/sqoop/blob/cfe27340/repository/repository-common/src/main/java/org/apache/sqoop/repository/common/CommonRepositorySchemaConstants.java
----------------------------------------------------------------------
diff --git a/repository/repository-common/src/main/java/org/apache/sqoop/repository/common/CommonRepositorySchemaConstants.java b/repository/repository-common/src/main/java/org/apache/sqoop/repository/common/CommonRepositorySchemaConstants.java
index 5ce9488..6e183de 100644
--- a/repository/repository-common/src/main/java/org/apache/sqoop/repository/common/CommonRepositorySchemaConstants.java
+++ b/repository/repository-common/src/main/java/org/apache/sqoop/repository/common/CommonRepositorySchemaConstants.java
@@ -27,12 +27,20 @@ public final class CommonRepositorySchemaConstants {
 
   public static final String CONSTRAINT_PREFIX = "FK_";
 
+  // SQ_SYSTEM
+
+  public static final String TABLE_SQ_SYSTEM_NAME = "SQ_SYSTEM";
+
+  public static final String COLUMN_SQM_ID = "SQM_ID";
+
+  public static final String COLUMN_SQM_KEY = "SQM_KEY";
+
+  public static final String COLUMN_SQM_VALUE = "SQM_VALUE";
+
   // SQ_DIRECTION
 
   public static final String TABLE_SQ_DIRECTION_NAME = "SQ_DIRECTION";
 
-  public static final String TABLE_SQ_DIRECTION = SCHEMA_PREFIX + TABLE_SQ_DIRECTION_NAME;
-
   public static final String COLUMN_SQD_ID = "SQD_ID";
 
   public static final String COLUMN_SQD_NAME = "SQD_NAME";
@@ -41,8 +49,6 @@ public final class CommonRepositorySchemaConstants {
 
   public static final String TABLE_SQ_CONFIGURABLE_NAME = "SQ_CONFIGURABLE";
 
-  public static final String TABLE_SQ_CONFIGURABLE = SCHEMA_PREFIX + TABLE_SQ_CONFIGURABLE_NAME;
-
   public static final String COLUMN_SQC_ID = "SQC_ID";
 
   public static final String COLUMN_SQC_NAME = "SQC_NAME";
@@ -57,9 +63,6 @@ public final class CommonRepositorySchemaConstants {
 
   public static final String TABLE_SQ_CONNECTOR_DIRECTIONS_NAME = "SQ_CONNECTOR_DIRECTIONS";
 
-  public static final String TABLE_SQ_CONNECTOR_DIRECTIONS = SCHEMA_PREFIX
-      + TABLE_SQ_CONNECTOR_DIRECTIONS_NAME;
-
   public static final String COLUMN_SQCD_ID = "SQCD_ID";
 
   public static final String COLUMN_SQCD_CONNECTOR = "SQCD_CONNECTOR";
@@ -70,8 +73,6 @@ public final class CommonRepositorySchemaConstants {
 
   public static final String TABLE_SQ_CONFIG_NAME = "SQ_CONFIG";
 
-  public static final String TABLE_SQ_CONFIG = SCHEMA_PREFIX + TABLE_SQ_CONFIG_NAME;
-
   public static final String COLUMN_SQ_CFG_ID = "SQ_CFG_ID";
 
   public static final String COLUMN_SQ_CFG_CONFIGURABLE = "SQ_CFG_CONFIGURABLE";
@@ -88,8 +89,7 @@ public final class CommonRepositorySchemaConstants {
 
   public static final String TABLE_SQ_CONFIG_DIRECTIONS_NAME = "SQ_CONFIG_DIRECTIONS";
 
-  public static final String TABLE_SQ_CONFIG_DIRECTIONS = SCHEMA_PREFIX
-      + TABLE_SQ_CONFIG_DIRECTIONS_NAME;
+  public static final String COLUMN_SQ_CFG_DIR_ID = "SQ_CFG_DIR_ID";
 
   public static final String COLUMN_SQ_CFG_DIR_CONFIG = "SQ_CFG_DIR_CONFIG";
 
@@ -99,8 +99,6 @@ public final class CommonRepositorySchemaConstants {
 
   public static final String TABLE_SQ_INPUT_NAME = "SQ_INPUT";
 
-  public static final String TABLE_SQ_INPUT = SCHEMA_PREFIX + TABLE_SQ_INPUT_NAME;
-
   public static final String COLUMN_SQI_ID = "SQI_ID";
 
   public static final String COLUMN_SQI_NAME = "SQI_NAME";
@@ -132,8 +130,6 @@ public final class CommonRepositorySchemaConstants {
 
   public static final String TABLE_SQ_LINK_NAME = "SQ_LINK";
 
-  public static final String TABLE_SQ_LINK = SCHEMA_PREFIX + TABLE_SQ_LINK_NAME;
-
   public static final String COLUMN_SQ_LNK_ID = "SQ_LNK_ID";
 
   public static final String COLUMN_SQ_LNK_NAME = "SQ_LNK_NAME";
@@ -154,8 +150,6 @@ public final class CommonRepositorySchemaConstants {
 
   public static final String TABLE_SQ_JOB_NAME = "SQ_JOB";
 
-  public static final String TABLE_SQ_JOB = SCHEMA_PREFIX + TABLE_SQ_JOB_NAME;
-
   public static final String COLUMN_SQB_ID = "SQB_ID";
 
   public static final String COLUMN_SQB_NAME = "SQB_NAME";
@@ -178,8 +172,6 @@ public final class CommonRepositorySchemaConstants {
 
   public static final String TABLE_SQ_LINK_INPUT_NAME = "SQ_LINK_INPUT";
 
-  public static final String TABLE_SQ_LINK_INPUT = SCHEMA_PREFIX + TABLE_SQ_LINK_INPUT_NAME;
-
   public static final String COLUMN_SQ_LNKI_LINK = "SQ_LNKI_LINK";
 
   public static final String COLUMN_SQ_LNKI_INPUT = "SQ_LNKI_INPUT";
@@ -190,8 +182,6 @@ public final class CommonRepositorySchemaConstants {
 
   public static final String TABLE_SQ_JOB_INPUT_NAME = "SQ_JOB_INPUT";
 
-  public static final String TABLE_SQ_JOB_INPUT = SCHEMA_PREFIX + TABLE_SQ_JOB_INPUT_NAME;
-
   public static final String COLUMN_SQBI_JOB = "SQBI_JOB";
 
   public static final String COLUMN_SQBI_INPUT = "SQBI_INPUT";
@@ -202,8 +192,6 @@ public final class CommonRepositorySchemaConstants {
 
   public static final String TABLE_SQ_SUBMISSION_NAME = "SQ_SUBMISSION";
 
-  public static final String TABLE_SQ_SUBMISSION = SCHEMA_PREFIX + TABLE_SQ_SUBMISSION_NAME;
-
   public static final String COLUMN_SQS_ID = "SQS_ID";
 
   public static final String COLUMN_SQS_JOB = "SQS_JOB";
@@ -230,8 +218,6 @@ public final class CommonRepositorySchemaConstants {
 
   public static final String TABLE_SQ_COUNTER_GROUP_NAME = "SQ_COUNTER_GROUP";
 
-  public static final String TABLE_SQ_COUNTER_GROUP = SCHEMA_PREFIX + TABLE_SQ_COUNTER_GROUP_NAME;
-
   public static final String COLUMN_SQG_ID = "SQG_ID";
 
   public static final String COLUMN_SQG_NAME = "SQG_NAME";
@@ -240,8 +226,6 @@ public final class CommonRepositorySchemaConstants {
 
   public static final String TABLE_SQ_COUNTER_NAME = "SQ_COUNTER";
 
-  public static final String TABLE_SQ_COUNTER = SCHEMA_PREFIX + TABLE_SQ_COUNTER_NAME;
-
   public static final String COLUMN_SQR_ID = "SQR_ID";
 
   public static final String COLUMN_SQR_NAME = "SQR_NAME";
@@ -250,9 +234,6 @@ public final class CommonRepositorySchemaConstants {
 
   public static final String TABLE_SQ_COUNTER_SUBMISSION_NAME = "SQ_COUNTER_SUBMISSION";
 
-  public static final String TABLE_SQ_COUNTER_SUBMISSION = SCHEMA_PREFIX
-      + TABLE_SQ_COUNTER_SUBMISSION_NAME;
-
   public static final String COLUMN_SQRS_GROUP = "SQRS_GROUP";
 
   public static final String COLUMN_SQRS_COUNTER = "SQRS_COUNTER";
@@ -261,6 +242,82 @@ public final class CommonRepositorySchemaConstants {
 
   public static final String COLUMN_SQRS_VALUE = "SQRS_VALUE";
 
+  // Constraints
+
+  // Constraints
+
+  public static final String CONSTRAINT_SQCD_SQC_NAME
+      = CONSTRAINT_PREFIX + "SQCD_SQC";
+
+  public static final String CONSTRAINT_SQCD_SQD_NAME
+      = CONSTRAINT_PREFIX + "SQCD_SQD";
+
+  public static final String CONSTRAINT_SQ_CONFIGURABLE_UNIQUE_NAME
+      = CONSTRAINT_PREFIX + "SQC_NAME_UNIQUE";
+
+  public static final String CONSTRAINT_SQ_CFG_DIR_CONFIG_NAME
+      = CONSTRAINT_PREFIX + "SQ_CFG_DIR_CONFIG";
+
+  public static final String CONSTRAINT_SQ_CFG_DIR_DIRECTION_NAME
+      = CONSTRAINT_PREFIX + "SQ_CFG_DIR_DIRECTION";
+
+  public static final String CONSTRAINT_SQ_CFG_SQC_NAME
+      = CONSTRAINT_PREFIX + "SQ_CFG_SQC";
+
+  public static final String CONSTRAINT_SQ_CONFIG_UNIQUE_NAME_TYPE_CONFIGURABLE
+      = CONSTRAINT_PREFIX + "SQ_CFG_NAME_TYPE_CONFIGURABLE_UNIQUE";
+
+  public static final String CONSTRAINT_SQI_SQ_CFG_NAME
+      = CONSTRAINT_PREFIX + "SQI_SQ_CFG";
+
+  public static final String CONSTRAINT_SQ_INPUT_UNIQUE_NAME_TYPE_CONFIG
+      = CONSTRAINT_PREFIX + "SQI_NAME_TYPE_CONFIG_UNIQUE";
+
+  public static final String CONSTRAINT_SQIR_PARENT_NAME
+      = CONSTRAINT_PREFIX + "SQIR_PARENT_ID";
+
+  public static final String CONSTRAINT_SQIR_CHILD_NAME
+      = CONSTRAINT_PREFIX + "SQIR_CHILD_ID";
+
+  public static final String CONSTRAINT_SQ_LNK_SQC_NAME
+      = CONSTRAINT_PREFIX + "SQ_LNK_SQC";
+
+  public static final String CONSTRAINT_SQ_LNK_NAME_UNIQUE_NAME
+      = CONSTRAINT_PREFIX + "SQ_LNK_NAME_UNIQUE";
+
+  public static final String CONSTRAINT_SQB_SQ_LNK_FROM_NAME
+      = CONSTRAINT_PREFIX + "SQB_SQ_LNK_FROM";
+
+  public static final String CONSTRAINT_SQB_SQ_LNK_TO_NAME
+      = CONSTRAINT_PREFIX + "SQB_SQ_LNK_TO";
+
+  public static final String CONSTRAINT_SQB_NAME_UNIQUE_NAME
+      = CONSTRAINT_PREFIX + "SQB_NAME_UNIQUE";
+
+  public static final String CONSTRAINT_SQ_LNKI_SQ_LNK_NAME
+      = CONSTRAINT_PREFIX + "SQ_LNKI_SQ_LNK";
+
+  public static final String CONSTRAINT_SQ_LNKI_SQI_NAME
+      = CONSTRAINT_PREFIX + "SQ_LNKI_SQI";
+
+  public static final String CONSTRAINT_SQBI_SQB_NAME
+      = CONSTRAINT_PREFIX + "SQBI_SQB";
+
+  public static final String CONSTRAINT_SQBI_SQI_NAME
+      = CONSTRAINT_PREFIX + "SQBI_SQI";
+
+  public static final String CONSTRAINT_SQS_SQB_NAME
+      = CONSTRAINT_PREFIX + "SQS_SQB";
+
+  public static final String CONSTRAINT_SQRS_SQG_NAME
+      = CONSTRAINT_PREFIX + "SQRS_SQG";
+
+  public static final String CONSTRAINT_SQRS_SQR_NAME
+      = CONSTRAINT_PREFIX + "SQRS_SQR";
+
+  public static final String CONSTRAINT_SQRS_SQS_NAME
+      = CONSTRAINT_PREFIX + "SQRS_SQS";
+
   private CommonRepositorySchemaConstants() {
     // Disable explicit object creation
   }

http://git-wip-us.apache.org/repos/asf/sqoop/blob/cfe27340/repository/repository-derby/src/main/java/org/apache/sqoop/repository/derby/DerbyRepositoryHandler.java
----------------------------------------------------------------------
diff --git a/repository/repository-derby/src/main/java/org/apache/sqoop/repository/derby/DerbyRepositoryHandler.java b/repository/repository-derby/src/main/java/org/apache/sqoop/repository/derby/DerbyRepositoryHandler.java
index c991e5c..f7bab09 100644
--- a/repository/repository-derby/src/main/java/org/apache/sqoop/repository/derby/DerbyRepositoryHandler.java
+++ b/repository/repository-derby/src/main/java/org/apache/sqoop/repository/derby/DerbyRepositoryHandler.java
@@ -52,6 +52,7 @@ import org.apache.sqoop.model.MInputType;
 import org.apache.sqoop.repository.JdbcRepositoryContext;
 import org.apache.sqoop.repository.common.CommonRepoConstants;
 import org.apache.sqoop.repository.common.CommonRepositoryHandler;
+import org.apache.sqoop.repository.common.CommonRepositorySchemaConstants;
 
 /**
  * JDBC based repository handler for Derby database.
@@ -166,7 +167,7 @@ public class DerbyRepositoryHandler extends CommonRepositoryHandler {
       }
 
       // If we find all expected tables, then we are on version 1
-      if(foundAll && !tableNames.contains(DerbySchemaConstants.TABLE_SQ_SYSTEM_NAME)) {
+      if(foundAll && !tableNames.contains(CommonRepositorySchemaConstants.TABLE_SQ_SYSTEM_NAME)) {
         return 1;
       }
 

http://git-wip-us.apache.org/repos/asf/sqoop/blob/cfe27340/repository/repository-derby/src/main/java/org/apache/sqoop/repository/derby/DerbySchemaConstants.java
----------------------------------------------------------------------
diff --git a/repository/repository-derby/src/main/java/org/apache/sqoop/repository/derby/DerbySchemaConstants.java b/repository/repository-derby/src/main/java/org/apache/sqoop/repository/derby/DerbySchemaConstants.java
index 8504091..7678d35 100644
--- a/repository/repository-derby/src/main/java/org/apache/sqoop/repository/derby/DerbySchemaConstants.java
+++ b/repository/repository-derby/src/main/java/org/apache/sqoop/repository/derby/DerbySchemaConstants.java
@@ -27,41 +27,11 @@ import java.util.Set;
 // PLEASE DO NOT ADD COMMON CONSTANTS HERE
 public final class DerbySchemaConstants {
 
-  // SQ_SYSTEM relevant only in derby
-  public static final String TABLE_SQ_SYSTEM_NAME = "SQ_SYSTEM";
-  public static final String TABLE_SQ_SYSTEM = SCHEMA_PREFIX + TABLE_SQ_SYSTEM_NAME;
-  public static final String COLUMN_SQM_ID = "SQM_ID";
-  public static final String COLUMN_SQM_KEY = "SQM_KEY";
-  public static final String COLUMN_SQM_VALUE = "SQM_VALUE";
-
   // SQ_CONNECTOR
   @Deprecated
   // used only for upgrade
   public static final String TABLE_SQ_CONNECTOR_NAME = "SQ_CONNECTOR";
 
-  @Deprecated
-  // used only for upgrade
-  public static final String TABLE_SQ_CONNECTOR = SCHEMA_PREFIX + TABLE_SQ_CONNECTOR_NAME;
-
-  // constraints relevant only in derby
-  public static final String CONSTRAINT_SQCD_SQC_NAME = CONSTRAINT_PREFIX + "SQCD_SQC";
-  // FK to the SQ_CONNECTOR table
-  public static final String CONSTRAINT_SQCD_SQC = SCHEMA_PREFIX + CONSTRAINT_SQCD_SQC_NAME;
-  public static final String CONSTRAINT_SQCD_SQD_NAME = CONSTRAINT_PREFIX + "SQCD_SQD";
-  // FK to the SQ_DIRECTION table
-  public static final String CONSTRAINT_SQCD_SQD = SCHEMA_PREFIX + CONSTRAINT_SQCD_SQD_NAME;
-
-  // SQ_CONFIGURABLE
-  //constraint only relevant in derby
-  public static final String CONSTRAINT_SQ_CONFIGURABLE_UNIQUE_NAME = CONSTRAINT_PREFIX
-      + "SQC_NAME_UNIQUE";
-  public static final String CONSTRAINT_SQ_CONFIGURABLE_UNIQUE = SCHEMA_PREFIX
-      + CONSTRAINT_SQ_CONFIGURABLE_UNIQUE_NAME;
-
-  // SQ_CONFIG_DIRECTION
-  // only relevant in derby
-  public static final String COLUMN_SQ_CFG_DIR_ID = "SQ_CFG_DIR_ID";
-
   // SQ_CONFIG
   @Deprecated
   // used only for upgrade
@@ -69,10 +39,6 @@ public final class DerbySchemaConstants {
 
   @Deprecated
   // used only for upgrade
-  public static final String TABLE_SQ_FORM = SCHEMA_PREFIX + TABLE_SQ_FORM_NAME;
-
-  @Deprecated
-  // used only for upgrade
   public static final String COLUMN_SQF_ID = "SQF_ID";
 
   @Deprecated
@@ -105,38 +71,6 @@ public final class DerbySchemaConstants {
   @Deprecated
   // used only for upgrade
   public static final String CONSTRAINT_SQF_SQC_NAME = CONSTRAINT_PREFIX + "SQF_SQC";
-  @Deprecated
-  // used only for upgrade
-  public static final String CONSTRAINT_SQF_SQC = SCHEMA_PREFIX + CONSTRAINT_SQF_SQC_NAME;
-
-  @Deprecated
-  // used only for the upgrade code
-  public static final String COLUMN_SQ_CFG_DIR_FORM = "SQ_CFG_DIR_FORM";
-
-  // constraint relevant only in derby
-  public static final String CONSTRAINT_SQ_CFG_DIR_CONFIG_NAME = CONSTRAINT_PREFIX
-      + "SQ_CFG_DIR_CONFIG";
-
-  // this is a FK to the SQ_CONFIG table
-  public static final String CONSTRAINT_SQ_CFG_DIR_CONFIG = SCHEMA_PREFIX
-      + CONSTRAINT_SQ_CFG_DIR_CONFIG_NAME;
-
-  public static final String CONSTRAINT_SQ_CFG_DIR_DIRECTION_NAME = CONSTRAINT_PREFIX
-      + "SQ_CFG_DIR_DIRECTION";
-
-  // this a FK to the SQ_DIRECTION table
-  public static final String CONSTRAINT_SQ_CFG_DIR_DIRECTION = SCHEMA_PREFIX
-      + CONSTRAINT_SQ_CFG_DIR_DIRECTION_NAME;
-
-  // FK constraint on configurable
-  public static final String CONSTRAINT_SQ_CFG_SQC_NAME = CONSTRAINT_PREFIX + "SQ_CFG_SQC";
-  public static final String CONSTRAINT_SQ_CFG_SQC = SCHEMA_PREFIX + CONSTRAINT_SQ_CFG_SQC_NAME;
-
-  // uniqueness constraint
-  public static final String CONSTRAINT_SQ_CONFIG_UNIQUE_NAME_TYPE_CONFIGURABLE = CONSTRAINT_PREFIX
-      + "SQ_CFG_NAME_TYPE_CONFIGURABLE_UNIQUE";
-  public static final String CONSTRAINT_SQ_CONFIG_UNIQUE = SCHEMA_PREFIX
-      + CONSTRAINT_SQ_CONFIG_UNIQUE_NAME_TYPE_CONFIGURABLE;
 
   @Deprecated
   // used only for upgrade
@@ -145,29 +79,6 @@ public final class DerbySchemaConstants {
   @Deprecated
   // used only for upgrade
   public static final String CONSTRAINT_SQI_SQF_NAME = CONSTRAINT_PREFIX + "SQI_SQF";
-  @Deprecated
-  // used only for upgrade
-  public static final String CONSTRAINT_SQI_SQF = SCHEMA_PREFIX + CONSTRAINT_SQI_SQF_NAME;
-
-  // constraints relevant only in derby
-
-  public static final String CONSTRAINT_SQI_SQ_CFG_NAME = CONSTRAINT_PREFIX + "SQI_SQ_CFG";
-  public static final String CONSTRAINT_SQI_SQ_CFG = SCHEMA_PREFIX + CONSTRAINT_SQI_SQ_CFG_NAME;
-
-  // uniqueness constraint
-  public static final String CONSTRAINT_SQ_INPUT_UNIQUE_NAME_TYPE_CONFIG = CONSTRAINT_PREFIX
-      + "SQI_NAME_TYPE_CONFIG_UNIQUE";
-  public static final String CONSTRAINT_SQ_INPUT_UNIQUE = SCHEMA_PREFIX
-      + CONSTRAINT_SQ_INPUT_UNIQUE_NAME_TYPE_CONFIG;
-
-  // SQ_INPUT_RELATION FK
-
-  public static final String CONSTRAINT_SQIR_PARENT_NAME = CONSTRAINT_PREFIX + "SQIR_PARENT_ID";
-  public static final String CONSTRAINT_SQIR_PARENT = SCHEMA_PREFIX + CONSTRAINT_SQIR_PARENT_NAME;
-
-  public static final String CONSTRAINT_SQIR_CHILD_NAME = CONSTRAINT_PREFIX + "SQIR_CHILD_ID";
-  public static final String CONSTRAINT_SQIR_CHILD = SCHEMA_PREFIX + CONSTRAINT_SQIR_CHILD_NAME;
-
 
   // SQ_LINK
   @Deprecated
@@ -176,10 +87,6 @@ public final class DerbySchemaConstants {
 
   @Deprecated
   // used only for upgrade
-  public static final String TABLE_SQ_CONNECTION = SCHEMA_PREFIX + TABLE_SQ_CONNECTION_NAME;
-
-  @Deprecated
-  // used only for upgrade
   public static final String COLUMN_SQN_ID = "SQN_ID";
   @Deprecated
   // used only for upgrade
@@ -209,17 +116,6 @@ public final class DerbySchemaConstants {
   // constraints relevant only in derby
   @Deprecated
   public static final String CONSTRAINT_SQN_SQC_NAME = CONSTRAINT_PREFIX + "SQN_SQC";
-  public static final String CONSTRAINT_SQ_LNK_SQC_NAME = CONSTRAINT_PREFIX + "SQ_LNK_SQC";
-
-  @Deprecated
-  public static final String CONSTRAINT_SQN_SQC = SCHEMA_PREFIX + CONSTRAINT_SQN_SQC_NAME;
-  // FK constraint on the connector configurable
-  public static final String CONSTRAINT_SQ_LNK_SQC = SCHEMA_PREFIX + CONSTRAINT_SQ_LNK_SQC_NAME;
-
-  public static final String CONSTRAINT_SQ_LNK_NAME_UNIQUE_NAME = CONSTRAINT_PREFIX
-      + "SQ_LNK_NAME_UNIQUE";
-  public static final String CONSTRAINT_SQ_LNK_NAME_UNIQUE = SCHEMA_PREFIX
-      + CONSTRAINT_SQ_LNK_NAME_UNIQUE_NAME;
 
   // SQ_CONNECTION
   @Deprecated
@@ -242,41 +138,10 @@ public final class DerbySchemaConstants {
   public static final String CONSTRAINT_SQB_SQN_NAME = CONSTRAINT_PREFIX + "SQB_SQN";
   @Deprecated
   // used only for upgrade
-  public static final String CONSTRAINT_SQB_SQN = SCHEMA_PREFIX + CONSTRAINT_SQB_SQN_NAME;
-  @Deprecated
-  // used only for upgrade
   public static final String CONSTRAINT_SQB_SQN_FROM_NAME = CONSTRAINT_PREFIX + "SQB_SQN_FROM";
   @Deprecated
   // used only for upgrade
-  public static final String CONSTRAINT_SQB_SQN_FROM = SCHEMA_PREFIX + CONSTRAINT_SQB_SQN_FROM_NAME;
-  @Deprecated
-  // used only for upgrade
   public static final String CONSTRAINT_SQB_SQN_TO_NAME = CONSTRAINT_PREFIX + "SQB_SQN_TO";
-  @Deprecated
-  // used only for upgrade
-  public static final String CONSTRAINT_SQB_SQN_TO = SCHEMA_PREFIX + CONSTRAINT_SQB_SQN_TO_NAME;
-
-  public static final String CONSTRAINT_SQB_SQ_LNK_NAME = CONSTRAINT_PREFIX + "SQB_SQ_LNK";
-
-  public static final String CONSTRAINT_SQB_SQ_LNK = SCHEMA_PREFIX + CONSTRAINT_SQB_SQ_LNK_NAME;
-
-  public static final String CONSTRAINT_SQB_SQ_LNK_FROM_NAME = CONSTRAINT_PREFIX
-      + "SQB_SQ_LNK_FROM";
-
-  public static final String CONSTRAINT_SQB_SQ_LNK_FROM = SCHEMA_PREFIX
-      + CONSTRAINT_SQB_SQ_LNK_FROM_NAME;
-
-  public static final String CONSTRAINT_SQB_SQ_LNK_TO_NAME = CONSTRAINT_PREFIX + "SQB_SQ_LNK_TO";
-
-  public static final String CONSTRAINT_SQB_SQ_LNK_TO = SCHEMA_PREFIX
-      + CONSTRAINT_SQB_SQ_LNK_TO_NAME;
-
-  public static final String CONSTRAINT_SQB_NAME_UNIQUE_NAME = CONSTRAINT_PREFIX
-      + "SQB_NAME_UNIQUE";
-
-  // relevant constraints relevant only in derby
-  public static final String CONSTRAINT_SQB_NAME_UNIQUE = SCHEMA_PREFIX
-      + CONSTRAINT_SQB_NAME_UNIQUE_NAME;
 
   // SQ_LINK_INPUT
   @Deprecated
@@ -285,11 +150,6 @@ public final class DerbySchemaConstants {
 
   @Deprecated
   // only used for upgrade
-  public static final String TABLE_SQ_CONNECTION_INPUT = SCHEMA_PREFIX
-      + TABLE_SQ_CONNECTION_INPUT_NAME;
-
-  @Deprecated
-  // only used for upgrade
   public static final String COLUMN_SQNI_CONNECTION = "SQNI_CONNECTION";
 
   @Deprecated
@@ -304,37 +164,10 @@ public final class DerbySchemaConstants {
   @Deprecated
   // only used for upgrade
   public static final String CONSTRAINT_SQNI_SQN_NAME = CONSTRAINT_PREFIX + "SQNI_SQN";
-  public static final String CONSTRAINT_SQ_LNKI_SQ_LNK_NAME = CONSTRAINT_PREFIX + "SQ_LNKI_SQ_LNK";
-
-  @Deprecated
-  // only used for upgrade
-  public static final String CONSTRAINT_SQNI_SQN = SCHEMA_PREFIX + CONSTRAINT_SQNI_SQN_NAME;
-  public static final String CONSTRAINT_SQ_LNKI_SQ_LNK = SCHEMA_PREFIX
-      + CONSTRAINT_SQ_LNKI_SQ_LNK_NAME;
 
   @Deprecated
   // only used for upgrade
   public static final String CONSTRAINT_SQNI_SQI_NAME = CONSTRAINT_PREFIX + "SQNI_SQI";
-  public static final String CONSTRAINT_SQ_LNKI_SQI_NAME = CONSTRAINT_PREFIX + "SQ_LNKI_SQI";
-  @Deprecated
-  // only used for upgrade
-  public static final String CONSTRAINT_SQNI_SQI = SCHEMA_PREFIX + CONSTRAINT_SQNI_SQI_NAME;
-  public static final String CONSTRAINT_SQ_LNKI_SQI = SCHEMA_PREFIX + CONSTRAINT_SQ_LNKI_SQI_NAME;
-
-  // SQ_JOB_INPUT
-  // constraints relevant only in derby
-  public static final String CONSTRAINT_SQBI_SQB_NAME = CONSTRAINT_PREFIX + "SQBI_SQB";
-
-  public static final String CONSTRAINT_SQBI_SQB = SCHEMA_PREFIX + CONSTRAINT_SQBI_SQB_NAME;
-
-  public static final String CONSTRAINT_SQBI_SQI_NAME = CONSTRAINT_PREFIX + "SQBI_SQI";
-
-  public static final String CONSTRAINT_SQBI_SQI = SCHEMA_PREFIX + CONSTRAINT_SQBI_SQI_NAME;
-
-  // SQ_SUBMISSION
-  public static final String CONSTRAINT_SQS_SQB_NAME = CONSTRAINT_PREFIX + "SQS_SQB";
-
-  public static final String CONSTRAINT_SQS_SQB = SCHEMA_PREFIX + CONSTRAINT_SQS_SQB_NAME;
 
   @Deprecated
  // used only for upgrade
@@ -343,20 +176,6 @@ public final class DerbySchemaConstants {
  // used only for upgrade
   public static final String COLUMN_SQS_EXCEPTION_TRACE = "SQS_EXCEPTION_TRACE";
 
-  // SQ_COUNTER_SUBMISSION
-  // constraints relevant only in derby
-  public static final String CONSTRAINT_SQRS_SQG_NAME = CONSTRAINT_PREFIX + "SQRS_SQG";
-
-  public static final String CONSTRAINT_SQRS_SQG = SCHEMA_PREFIX + CONSTRAINT_SQRS_SQG_NAME;
-
-  public static final String CONSTRAINT_SQRS_SQR_NAME = CONSTRAINT_PREFIX + "SQRS_SQR";
-
-  public static final String CONSTRAINT_SQRS_SQR = SCHEMA_PREFIX + CONSTRAINT_SQRS_SQR_NAME;
-
-  public static final String CONSTRAINT_SQRS_SQS_NAME = CONSTRAINT_PREFIX + "SQRS_SQS";
-
-  public static final String CONSTRAINT_SQRS_SQS = SCHEMA_PREFIX + CONSTRAINT_SQRS_SQS_NAME;
-
   /**
    * List of expected tables for first version; This list here is for backward
    * compatibility.

http://git-wip-us.apache.org/repos/asf/sqoop/blob/cfe27340/repository/repository-postgresql/src/main/java/org/apache/sqoop/repository/postgresql/PostgresqlRepositoryHandler.java
----------------------------------------------------------------------
diff --git a/repository/repository-postgresql/src/main/java/org/apache/sqoop/repository/postgresql/PostgresqlRepositoryHandler.java b/repository/repository-postgresql/src/main/java/org/apache/sqoop/repository/postgresql/PostgresqlRepositoryHandler.java
index 3740f8d..f54bd22 100644
--- a/repository/repository-postgresql/src/main/java/org/apache/sqoop/repository/postgresql/PostgresqlRepositoryHandler.java
+++ b/repository/repository-postgresql/src/main/java/org/apache/sqoop/repository/postgresql/PostgresqlRepositoryHandler.java
@@ -24,6 +24,7 @@ import org.apache.sqoop.error.code.PostgresqlRepoError;
 import org.apache.sqoop.repository.JdbcRepositoryContext;
 import org.apache.sqoop.repository.common.CommonRepoConstants;
 import org.apache.sqoop.repository.common.CommonRepositoryHandler;
+import org.apache.sqoop.repository.common.CommonRepositorySchemaConstants;
 
 import java.sql.Connection;
 import java.sql.DatabaseMetaData;
@@ -78,8 +79,8 @@ public class PostgresqlRepositoryHandler extends CommonRepositoryHandler {
     try {
       DatabaseMetaData md = conn.getMetaData();
       metadataResultSet = md.getTables(null,
-          PostgresqlSchemaConstants.SCHEMA_SQOOP.toLowerCase(),
-          PostgresqlSchemaConstants.TABLE_SQ_SYSTEM_NAME.toLowerCase(), null);
+          CommonRepositorySchemaConstants.SCHEMA_SQOOP.toLowerCase(),
+          CommonRepositorySchemaConstants.TABLE_SQ_SYSTEM_NAME.toLowerCase(), null);
 
       if (metadataResultSet.next()) {
         stmt = conn.prepareStatement(PostgresqlSchemaQuery.STMT_SELECT_SYSTEM);

http://git-wip-us.apache.org/repos/asf/sqoop/blob/cfe27340/repository/repository-postgresql/src/main/java/org/apache/sqoop/repository/postgresql/PostgresqlSchemaConstants.java
----------------------------------------------------------------------
diff --git a/repository/repository-postgresql/src/main/java/org/apache/sqoop/repository/postgresql/PostgresqlSchemaConstants.java b/repository/repository-postgresql/src/main/java/org/apache/sqoop/repository/postgresql/PostgresqlSchemaConstants.java
deleted file mode 100644
index 50c98b7..0000000
--- a/repository/repository-postgresql/src/main/java/org/apache/sqoop/repository/postgresql/PostgresqlSchemaConstants.java
+++ /dev/null
@@ -1,358 +0,0 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.sqoop.repository.postgresql;
-
-import static org.apache.sqoop.repository.common.CommonRepositorySchemaConstants.CONSTRAINT_PREFIX;
-import static org.apache.sqoop.repository.common.CommonRepositorySchemaConstants.SCHEMA_PREFIX;
-
-public class PostgresqlSchemaConstants {
-  public static final String SCHEMA_SQOOP = "SQOOP";
-
-  private static final String SCHEMA_PREFIX = SCHEMA_SQOOP + ".";
-
-  // SQ_SYSTEM
-
-  public static final String TABLE_SQ_SYSTEM_NAME = "SQ_SYSTEM";
-
-  public static final String TABLE_SQ_SYSTEM = SCHEMA_PREFIX
-      + TABLE_SQ_SYSTEM_NAME;
-
-  public static final String COLUMN_SQM_ID = "SQM_ID";
-
-  public static final String COLUMN_SQM_KEY = "SQM_KEY";
-
-  public static final String COLUMN_SQM_VALUE = "SQM_VALUE";
-
-  // SQ_DIRECTION
-
-  public static final String TABLE_SQ_DIRECTION_NAME = "SQ_DIRECTION";
-
-  public static final String TABLE_SQ_DIRECTION = SCHEMA_PREFIX
-      + TABLE_SQ_DIRECTION_NAME;
-
-  public static final String COLUMN_SQD_ID = "SQD_ID";
-
-  public static final String COLUMN_SQD_NAME = "SQD_NAME";
-
-  // SQ_CONNECTOR
-
-  public static final String TABLE_SQ_CONFIGURABLE_NAME = "SQ_CONFIGURABLE";
-
-  public static final String TABLE_SQ_CONFIGURABLE = SCHEMA_PREFIX
-      + TABLE_SQ_CONFIGURABLE_NAME;
-
-  public static final String COLUMN_SQC_ID = "SQC_ID";
-
-  public static final String COLUMN_SQC_NAME = "SQC_NAME";
-
-  public static final String COLUMN_SQC_TYPE = "SQC_TYPE";
-
-  public static final String COLUMN_SQC_CLASS = "SQC_CLASS";
-
-  public static final String COLUMN_SQC_VERSION = "SQC_VERSION";
-
-  // SQ_CONNECTOR_DIRECTIONS
-
-  public static final String TABLE_SQ_CONNECTOR_DIRECTIONS_NAME = "SQ_CONNECTOR_DIRECTIONS";
-
-  public static final String TABLE_SQ_CONNECTOR_DIRECTIONS = SCHEMA_PREFIX
-      + TABLE_SQ_CONNECTOR_DIRECTIONS_NAME;
-
-  public static final String COLUMN_SQCD_ID = "SQCD_ID";
-
-  public static final String COLUMN_SQCD_CONNECTOR = "SQCD_CONNECTOR";
-
-  public static final String COLUMN_SQCD_DIRECTION = "SQCD_DIRECTION";
-
-  // SQ_CONFIG
-
-  public static final String TABLE_SQ_CONFIG_NAME = "SQ_CONFIG";
-
-  public static final String TABLE_SQ_CONFIG = SCHEMA_PREFIX
-      + TABLE_SQ_CONFIG_NAME;
-
-  public static final String COLUMN_SQ_CFG_ID = "SQ_CFG_ID";
-
-  public static final String COLUMN_SQ_CFG_CONFIGURABLE = "SQ_CFG_CONFIGURABLE";
-
-  public static final String COLUMN_SQ_CFG_NAME = "SQ_CFG_NAME";
-
-  public static final String COLUMN_SQ_CFG_TYPE = "SQ_CFG_TYPE";
-
-  public static final String COLUMN_SQ_CFG_INDEX = "SQ_CFG_INDEX";
-
-  // SQ_CONFIG_DIRECTIONS
-
-  public static final String TABLE_SQ_CONFIG_DIRECTIONS_NAME = "SQ_CONFIG_DIRECTIONS";
-
-  public static final String TABLE_SQ_CONFIG_DIRECTIONS = SCHEMA_PREFIX
-      + TABLE_SQ_CONFIG_DIRECTIONS_NAME;
-
-  public static final String COLUMN_SQ_CFG_DIR_ID = "SQ_CFG_DIR_ID";
-
-  public static final String COLUMN_SQ_CFG_DIR_CONFIG = "SQ_CFG_DIR_CONFIG";
-
-  public static final String COLUMN_SQ_CFG_DIR_DIRECTION = "SQ_CFG_DIR_DIRECTION";
-
-  // SQ_INPUT
-
-  public static final String TABLE_SQ_INPUT_NAME = "SQ_INPUT";
-
-  public static final String TABLE_SQ_INPUT = SCHEMA_PREFIX
-      + TABLE_SQ_INPUT_NAME;
-
-  public static final String COLUMN_SQI_ID = "SQI_ID";
-
-  public static final String COLUMN_SQI_NAME = "SQI_NAME";
-
-  public static final String COLUMN_SQI_CONFIG = "SQI_CONFIG";
-
-  public static final String COLUMN_SQI_INDEX = "SQI_INDEX";
-
-  public static final String COLUMN_SQI_TYPE = "SQI_TYPE";
-
-  public static final String COLUMN_SQI_STRMASK = "SQI_STRMASK";
-
-  public static final String COLUMN_SQI_STRLENGTH = "SQI_STRLENGTH";
-
-  public static final String COLUMN_SQI_ENUMVALS = "SQI_ENUMVALS";
-
-  public static final String TABLE_SQ_LINK_NAME = "SQ_LINK";
-
-  // SQ_LINK
-
-  public static final String TABLE_SQ_LINK = SCHEMA_PREFIX
-      + TABLE_SQ_LINK_NAME;
-
-  public static final String COLUMN_SQ_LNK_ID = "SQ_LNK_ID";
-
-  public static final String COLUMN_SQ_LNK_NAME = "SQ_LNK_NAME";
-
-  public static final String COLUMN_SQ_LNK_CONFIGURABLE = "SQ_LNK_CONFIGURABLE";
-
-  public static final String COLUMN_SQ_LNK_CREATION_USER = "SQ_LNK_CREATION_USER";
-
-  public static final String COLUMN_SQ_LNK_CREATION_DATE = "SQ_LNK_CREATION_DATE";
-
-  public static final String COLUMN_SQ_LNK_UPDATE_USER = "SQ_LNK_UPDATE_USER";
-
-  public static final String COLUMN_SQ_LNK_UPDATE_DATE = "SQ_LNK_UPDATE_DATE";
-
-  public static final String COLUMN_SQ_LNK_ENABLED = "SQ_LNK_ENABLED";
-
-  // SQ_JOB
-
-  public static final String TABLE_SQ_JOB_NAME = "SQ_JOB";
-
-  public static final String TABLE_SQ_JOB = SCHEMA_PREFIX
-      + TABLE_SQ_JOB_NAME;
-
-  public static final String COLUMN_SQB_ID = "SQB_ID";
-
-  public static final String COLUMN_SQB_NAME = "SQB_NAME";
-
-  public static final String COLUMN_SQB_FROM_LINK = "SQB_FROM_LINK";
-
-  public static final String COLUMN_SQB_TO_LINK = "SQB_TO_LINK";
-
-  public static final String COLUMN_SQB_CREATION_USER = "SQB_CREATION_USER";
-
-  public static final String COLUMN_SQB_CREATION_DATE = "SQB_CREATION_DATE";
-
-  public static final String COLUMN_SQB_UPDATE_USER = "SQB_UPDATE_USER";
-
-  public static final String COLUMN_SQB_UPDATE_DATE = "SQB_UPDATE_DATE";
-
-  public static final String COLUMN_SQB_ENABLED = "SQB_ENABLED";
-
-  // SQ_LINK_INPUT
-
-  public static final String TABLE_SQ_LINK_INPUT_NAME =
-      "SQ_LINK_INPUT";
-
-  public static final String TABLE_SQ_LINK_INPUT = SCHEMA_PREFIX
-      + TABLE_SQ_LINK_INPUT_NAME;
-
-  public static final String COLUMN_SQ_LNKI_LINK = "SQ_LNKI_LINK";
-
-  public static final String COLUMN_SQ_LNKI_INPUT = "SQ_LNKI_INPUT";
-
-  public static final String COLUMN_SQ_LNKI_VALUE = "SQ_LNKI_VALUE";
-
-  // SQ_JOB_INPUT
-
-  public static final String TABLE_SQ_JOB_INPUT_NAME =
-      "SQ_JOB_INPUT";
-
-  public static final String TABLE_SQ_JOB_INPUT = SCHEMA_PREFIX
-      + TABLE_SQ_JOB_INPUT_NAME;
-
-  public static final String COLUMN_SQBI_JOB = "SQBI_JOB";
-
-  public static final String COLUMN_SQBI_INPUT = "SQBI_INPUT";
-
-  public static final String COLUMN_SQBI_VALUE = "SQBI_VALUE";
-
-  // SQ_SUBMISSION
-
-  public static final String TABLE_SQ_SUBMISSION_NAME =
-      "SQ_SUBMISSION";
-
-  public static final String TABLE_SQ_SUBMISSION = SCHEMA_PREFIX
-      + TABLE_SQ_SUBMISSION_NAME;
-
-  public static final String COLUMN_SQS_ID = "SQS_ID";
-
-  public static final String COLUMN_SQS_JOB = "SQS_JOB";
-
-  public static final String COLUMN_SQS_STATUS = "SQS_STATUS";
-
-  public static final String COLUMN_SQS_CREATION_USER = "SQS_CREATION_USER";
-
-  public static final String COLUMN_SQS_CREATION_DATE = "SQS_CREATION_DATE";
-
-  public static final String COLUMN_SQS_UPDATE_USER = "SQS_UPDATE_USER";
-
-  public static final String COLUMN_SQS_UPDATE_DATE = "SQS_UPDATE_DATE";
-
-  public static final String COLUMN_SQS_EXTERNAL_ID = "SQS_EXTERNAL_ID";
-
-  public static final String COLUMN_SQS_EXTERNAL_LINK = "SQS_EXTERNAL_LINK";
-
-  public static final String COLUMN_SQS_ERROR_DETAILS = "SQS_ERROR_DETAILS";
-
-  public static final String COLUMN_SQS_ERROR_SUMMARY = "SQS_ERROR_SUMMARY";
-
-  // SQ_COUNTER_GROUP
-
-  public static final String TABLE_SQ_COUNTER_GROUP_NAME =
-      "SQ_COUNTER_GROUP";
-
-  public static final String TABLE_SQ_COUNTER_GROUP = SCHEMA_PREFIX
-      + TABLE_SQ_COUNTER_GROUP_NAME;
-
-  public static final String COLUMN_SQG_ID = "SQG_ID";
-
-  public static final String COLUMN_SQG_NAME = "SQG_NAME";
-
-  // SQ_COUNTER_GROUP
-
-  public static final String TABLE_SQ_COUNTER_NAME =
-      "SQ_COUNTER";
-
-  public static final String TABLE_SQ_COUNTER = SCHEMA_PREFIX
-      + TABLE_SQ_COUNTER_NAME;
-
-  public static final String COLUMN_SQR_ID = "SQR_ID";
-
-  public static final String COLUMN_SQR_NAME = "SQR_NAME";
-
-  // SQ_COUNTER_SUBMISSION
-
-  public static final String TABLE_SQ_COUNTER_SUBMISSION_NAME =
-      "SQ_COUNTER_SUBMISSION";
-
-  public static final String TABLE_SQ_COUNTER_SUBMISSION = SCHEMA_PREFIX
-      + TABLE_SQ_COUNTER_SUBMISSION_NAME;
-
-  public static final String COLUMN_SQRS_GROUP = "SQRS_GROUP";
-
-  public static final String COLUMN_SQRS_COUNTER = "SQRS_COUNTER";
-
-  public static final String COLUMN_SQRS_SUBMISSION = "SQRS_SUBMISSION";
-
-  public static final String COLUMN_SQRS_VALUE = "SQRS_VALUE";
-
-  // Constraints
-
-  public static final String CONSTRAINT_SQCD_SQC_NAME
-      = CONSTRAINT_PREFIX + "SQCD_SQC";
-
-  public static final String CONSTRAINT_SQCD_SQD_NAME
-      = CONSTRAINT_PREFIX + "SQCD_SQD";
-
-  public static final String CONSTRAINT_SQ_CONFIGURABLE_UNIQUE_NAME
-      = CONSTRAINT_PREFIX + "SQC_NAME_UNIQUE";
-
-  public static final String CONSTRAINT_SQ_CFG_DIR_CONFIG_NAME
-      = CONSTRAINT_PREFIX + "SQ_CFG_DIR_CONFIG";
-
-  public static final String CONSTRAINT_SQ_CFG_DIR_DIRECTION_NAME
-      = CONSTRAINT_PREFIX + "SQ_CFG_DIR_DIRECTION";
-
-  public static final String CONSTRAINT_SQ_CFG_SQC_NAME
-      = CONSTRAINT_PREFIX + "SQ_CFG_SQC";
-
-  public static final String CONSTRAINT_SQ_CONFIG_UNIQUE_NAME_TYPE_CONFIGURABLE
-      = CONSTRAINT_PREFIX + "SQ_CFG_NAME_TYPE_CONFIGURABLE_UNIQUE";
-
-  public static final String CONSTRAINT_SQI_SQ_CFG_NAME
-      = CONSTRAINT_PREFIX + "SQI_SQ_CFG";
-
-  public static final String CONSTRAINT_SQ_INPUT_UNIQUE_NAME_TYPE_CONFIG
-      = CONSTRAINT_PREFIX + "SQI_NAME_TYPE_CONFIG_UNIQUE";
-
-  public static final String CONSTRAINT_SQIR_PARENT_NAME
-      = CONSTRAINT_PREFIX + "SQIR_PARENT_ID";
-
-  public static final String CONSTRAINT_SQIR_CHILD_NAME
-      = CONSTRAINT_PREFIX + "SQIR_CHILD_ID";
-
-  public static final String CONSTRAINT_SQ_LNK_SQC_NAME
-      = CONSTRAINT_PREFIX + "SQ_LNK_SQC";
-
-  public static final String CONSTRAINT_SQ_LNK_NAME_UNIQUE_NAME
-      = CONSTRAINT_PREFIX + "SQ_LNK_NAME_UNIQUE";
-
-  public static final String CONSTRAINT_SQB_SQ_LNK_FROM_NAME
-      = CONSTRAINT_PREFIX + "SQB_SQ_LNK_FROM";
-
-  public static final String CONSTRAINT_SQB_SQ_LNK_TO_NAME
-      = CONSTRAINT_PREFIX + "SQB_SQ_LNK_TO";
-
-  public static final String CONSTRAINT_SQB_NAME_UNIQUE_NAME
-      = CONSTRAINT_PREFIX + "SQB_NAME_UNIQUE";
-
-  public static final String CONSTRAINT_SQ_LNKI_SQ_LNK_NAME
-      = CONSTRAINT_PREFIX + "SQ_LNKI_SQ_LNK";
-
-  public static final String CONSTRAINT_SQ_LNKI_SQI_NAME
-      = CONSTRAINT_PREFIX + "SQ_LNKI_SQI";
-
-  public static final String CONSTRAINT_SQBI_SQB_NAME
-      = CONSTRAINT_PREFIX + "SQBI_SQB";
-
-  public static final String CONSTRAINT_SQBI_SQI_NAME
-      = CONSTRAINT_PREFIX + "SQBI_SQI";
-
-  public static final String CONSTRAINT_SQS_SQB_NAME
-      = CONSTRAINT_PREFIX + "SQS_SQB";
-
-  public static final String CONSTRAINT_SQRS_SQG_NAME
-      = CONSTRAINT_PREFIX + "SQRS_SQG";
-
-  public static final String CONSTRAINT_SQRS_SQR_NAME
-      = CONSTRAINT_PREFIX + "SQRS_SQR";
-
-  public static final String CONSTRAINT_SQRS_SQS_NAME
-      = CONSTRAINT_PREFIX + "SQRS_SQS";
-
-  private PostgresqlSchemaConstants() {
-    // Disable explicit object creation
-  }
-}

http://git-wip-us.apache.org/repos/asf/sqoop/blob/cfe27340/repository/repository-postgresql/src/main/java/org/apache/sqoop/repository/postgresql/PostgresqlSchemaCreateQuery.java
----------------------------------------------------------------------
diff --git a/repository/repository-postgresql/src/main/java/org/apache/sqoop/repository/postgresql/PostgresqlSchemaCreateQuery.java b/repository/repository-postgresql/src/main/java/org/apache/sqoop/repository/postgresql/PostgresqlSchemaCreateQuery.java
index c02ab48..7e95be1 100644
--- a/repository/repository-postgresql/src/main/java/org/apache/sqoop/repository/postgresql/PostgresqlSchemaCreateQuery.java
+++ b/repository/repository-postgresql/src/main/java/org/apache/sqoop/repository/postgresql/PostgresqlSchemaCreateQuery.java
@@ -17,12 +17,10 @@
  */
 package org.apache.sqoop.repository.postgresql;
 
-import org.apache.sqoop.repository.common.CommonRepoConstants;
 import org.apache.sqoop.repository.common.CommonRepoUtils;
 import org.apache.sqoop.repository.common.CommonRepositorySchemaConstants;
 
 import static org.apache.sqoop.repository.common.CommonRepositorySchemaConstants.SCHEMA_SQOOP;
-import static org.apache.sqoop.repository.postgresql.PostgresqlSchemaConstants.*;
 
 /**
  * DDL queries that create the Sqoop repository schema in PostgreSQL database. These
@@ -255,86 +253,86 @@ public class PostgresqlSchemaCreateQuery {
       "CREATE SCHEMA " + CommonRepoUtils.escapeSchemaName(SCHEMA_SQOOP);
 
   public static final String QUERY_CREATE_TABLE_SQ_SYSTEM =
-      "CREATE TABLE " + CommonRepoUtils.getTableName(SCHEMA_SQOOP, TABLE_SQ_SYSTEM_NAME) + " ("
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQM_ID) + " BIGSERIAL PRIMARY KEY NOT NULL, "
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQM_KEY) + " VARCHAR(64), "
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQM_VALUE) + " VARCHAR(64) "
+      "CREATE TABLE " + CommonRepoUtils.getTableName(SCHEMA_SQOOP, CommonRepositorySchemaConstants.TABLE_SQ_SYSTEM_NAME) + " ("
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQM_ID) + " BIGSERIAL PRIMARY KEY NOT NULL, "
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQM_KEY) + " VARCHAR(64), "
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQM_VALUE) + " VARCHAR(64) "
           + ")";
 
   public static final String QUERY_CREATE_TABLE_SQ_DIRECTION =
-      "CREATE TABLE " + CommonRepoUtils.getTableName(SCHEMA_SQOOP, TABLE_SQ_DIRECTION_NAME) + " ("
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQD_ID) + " BIGSERIAL PRIMARY KEY NOT NULL, "
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQD_NAME) + " VARCHAR(64)"
+      "CREATE TABLE " + CommonRepoUtils.getTableName(SCHEMA_SQOOP, CommonRepositorySchemaConstants.TABLE_SQ_DIRECTION_NAME) + " ("
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQD_ID) + " BIGSERIAL PRIMARY KEY NOT NULL, "
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQD_NAME) + " VARCHAR(64)"
           + ")";
 
   public static final String QUERY_CREATE_TABLE_SQ_CONFIGURABLE =
-      "CREATE TABLE " + CommonRepoUtils.getTableName(SCHEMA_SQOOP, TABLE_SQ_CONFIGURABLE_NAME) + " ("
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQC_ID) + " BIGSERIAL PRIMARY KEY NOT NULL, "
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQC_NAME) + " VARCHAR(64) CONSTRAINT "
-            + CommonRepoUtils.escapeConstraintName(CONSTRAINT_SQ_CONFIGURABLE_UNIQUE_NAME) + " UNIQUE, "
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQC_TYPE) + " VARCHAR(32), "
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQC_CLASS) + " VARCHAR(255), "
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQC_VERSION) + " VARCHAR(64) "
+      "CREATE TABLE " + CommonRepoUtils.getTableName(SCHEMA_SQOOP, CommonRepositorySchemaConstants.TABLE_SQ_CONFIGURABLE_NAME) + " ("
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQC_ID) + " BIGSERIAL PRIMARY KEY NOT NULL, "
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQC_NAME) + " VARCHAR(64) CONSTRAINT "
+            + CommonRepoUtils.escapeConstraintName(CommonRepositorySchemaConstants.CONSTRAINT_SQ_CONFIGURABLE_UNIQUE_NAME) + " UNIQUE, "
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQC_TYPE) + " VARCHAR(32), "
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQC_CLASS) + " VARCHAR(255), "
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQC_VERSION) + " VARCHAR(64) "
           + ")";
 
   public static final String QUERY_CREATE_TABLE_SQ_CONNECTOR_DIRECTIONS =
-      "CREATE TABLE " + CommonRepoUtils.getTableName(SCHEMA_SQOOP, TABLE_SQ_CONNECTOR_DIRECTIONS_NAME) + " ("
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQCD_ID) + " BIGSERIAL PRIMARY KEY NOT NULL, "
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQCD_CONNECTOR) + " BIGINT, "
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQCD_DIRECTION) + " BIGINT, "
-          + "CONSTRAINT " + CommonRepoUtils.escapeConstraintName(CONSTRAINT_SQCD_SQC_NAME)
-            + " FOREIGN KEY (" + CommonRepoUtils.escapeColumnName(COLUMN_SQCD_CONNECTOR) + ") REFERENCES "
-              + CommonRepoUtils.getTableName(SCHEMA_SQOOP, TABLE_SQ_CONFIGURABLE_NAME) + "("  + CommonRepoUtils.escapeColumnName(COLUMN_SQC_ID) + "), "
-          + "CONSTRAINT " + CommonRepoUtils.escapeConstraintName(CONSTRAINT_SQCD_SQD_NAME)
-            + " FOREIGN KEY (" + CommonRepoUtils.escapeColumnName(COLUMN_SQCD_DIRECTION) + ") REFERENCES "
-              + CommonRepoUtils.getTableName(SCHEMA_SQOOP, TABLE_SQ_DIRECTION_NAME) + "("  + CommonRepoUtils.escapeColumnName(COLUMN_SQD_ID) + ")"
+      "CREATE TABLE " + CommonRepoUtils.getTableName(SCHEMA_SQOOP, CommonRepositorySchemaConstants.TABLE_SQ_CONNECTOR_DIRECTIONS_NAME) + " ("
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQCD_ID) + " BIGSERIAL PRIMARY KEY NOT NULL, "
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQCD_CONNECTOR) + " BIGINT, "
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQCD_DIRECTION) + " BIGINT, "
+          + "CONSTRAINT " + CommonRepoUtils.escapeConstraintName(CommonRepositorySchemaConstants.CONSTRAINT_SQCD_SQC_NAME)
+            + " FOREIGN KEY (" + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQCD_CONNECTOR) + ") REFERENCES "
+              + CommonRepoUtils.getTableName(SCHEMA_SQOOP, CommonRepositorySchemaConstants.TABLE_SQ_CONFIGURABLE_NAME) + "("  + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQC_ID) + "), "
+          + "CONSTRAINT " + CommonRepoUtils.escapeConstraintName(CommonRepositorySchemaConstants.CONSTRAINT_SQCD_SQD_NAME)
+            + " FOREIGN KEY (" + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQCD_DIRECTION) + ") REFERENCES "
+              + CommonRepoUtils.getTableName(SCHEMA_SQOOP, CommonRepositorySchemaConstants.TABLE_SQ_DIRECTION_NAME) + "("  + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQD_ID) + ")"
           + ")";
 
   public static final String QUERY_CREATE_TABLE_SQ_CONFIG =
-      "CREATE TABLE " + CommonRepoUtils.getTableName(SCHEMA_SQOOP, TABLE_SQ_CONFIG_NAME) + " ("
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQ_CFG_ID) + " BIGSERIAL PRIMARY KEY NOT NULL, "
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQ_CFG_CONFIGURABLE) + " BIGINT, "
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQ_CFG_NAME) + " VARCHAR(64), "
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQ_CFG_TYPE) + " VARCHAR(32), "
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQ_CFG_INDEX) + " SMALLINT, "
-          + "CONSTRAINT " + CommonRepoUtils.escapeConstraintName(CONSTRAINT_SQ_CFG_SQC_NAME)
-            + " FOREIGN KEY (" + CommonRepoUtils.escapeColumnName(COLUMN_SQ_CFG_CONFIGURABLE) + ") REFERENCES "
-              + CommonRepoUtils.getTableName(SCHEMA_SQOOP, TABLE_SQ_CONFIGURABLE_NAME) + "("  + CommonRepoUtils.escapeColumnName(COLUMN_SQC_ID) + "),"
-          + "CONSTRAINT " + CommonRepoUtils.escapeConstraintName(CONSTRAINT_SQ_CONFIG_UNIQUE_NAME_TYPE_CONFIGURABLE)
-            + " UNIQUE (" + CommonRepoUtils.escapeColumnName(COLUMN_SQ_CFG_NAME) + ", " + CommonRepoUtils.escapeColumnName(COLUMN_SQ_CFG_TYPE) + ", " + CommonRepoUtils.escapeColumnName(COLUMN_SQ_CFG_CONFIGURABLE) + ") "
+      "CREATE TABLE " + CommonRepoUtils.getTableName(SCHEMA_SQOOP, CommonRepositorySchemaConstants.TABLE_SQ_CONFIG_NAME) + " ("
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQ_CFG_ID) + " BIGSERIAL PRIMARY KEY NOT NULL, "
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQ_CFG_CONFIGURABLE) + " BIGINT, "
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQ_CFG_NAME) + " VARCHAR(64), "
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQ_CFG_TYPE) + " VARCHAR(32), "
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQ_CFG_INDEX) + " SMALLINT, "
+          + "CONSTRAINT " + CommonRepoUtils.escapeConstraintName(CommonRepositorySchemaConstants.CONSTRAINT_SQ_CFG_SQC_NAME)
+            + " FOREIGN KEY (" + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQ_CFG_CONFIGURABLE) + ") REFERENCES "
+              + CommonRepoUtils.getTableName(SCHEMA_SQOOP, CommonRepositorySchemaConstants.TABLE_SQ_CONFIGURABLE_NAME) + "("  + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQC_ID) + "),"
+          + "CONSTRAINT " + CommonRepoUtils.escapeConstraintName(CommonRepositorySchemaConstants.CONSTRAINT_SQ_CONFIG_UNIQUE_NAME_TYPE_CONFIGURABLE)
+            + " UNIQUE (" + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQ_CFG_NAME) + ", " + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQ_CFG_TYPE) + ", " + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQ_CFG_CONFIGURABLE) + ") "
           + ")";
 
   public static final String QUERY_CREATE_TABLE_SQ_CONFIG_DIRECTIONS =
-      "CREATE TABLE " + CommonRepoUtils.getTableName(SCHEMA_SQOOP, TABLE_SQ_CONFIG_DIRECTIONS_NAME) + " ("
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQ_CFG_DIR_ID) + " BIGSERIAL PRIMARY KEY NOT NULL, "
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQ_CFG_DIR_CONFIG) + " BIGINT, "
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQ_CFG_DIR_DIRECTION) + " BIGINT, "
-          + "CONSTRAINT " + CommonRepoUtils.escapeConstraintName(CONSTRAINT_SQ_CFG_DIR_CONFIG_NAME)
-            + " FOREIGN KEY (" + CommonRepoUtils.escapeColumnName(COLUMN_SQ_CFG_DIR_CONFIG) + ") REFERENCES "
-              + CommonRepoUtils.getTableName(SCHEMA_SQOOP, TABLE_SQ_CONFIG_NAME) + "("  + CommonRepoUtils.escapeColumnName(COLUMN_SQ_CFG_ID) + "), "
-          + "CONSTRAINT " + CommonRepoUtils.escapeConstraintName(CONSTRAINT_SQ_CFG_DIR_DIRECTION_NAME)
-            + " FOREIGN KEY (" + CommonRepoUtils.escapeColumnName(COLUMN_SQ_CFG_DIR_DIRECTION) + ") REFERENCES "
-              + CommonRepoUtils.getTableName(SCHEMA_SQOOP, TABLE_SQ_DIRECTION_NAME) + "("  + CommonRepoUtils.escapeColumnName(COLUMN_SQD_ID) + ")"
+      "CREATE TABLE " + CommonRepoUtils.getTableName(SCHEMA_SQOOP, CommonRepositorySchemaConstants.TABLE_SQ_CONFIG_DIRECTIONS_NAME) + " ("
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQ_CFG_DIR_ID) + " BIGSERIAL PRIMARY KEY NOT NULL, "
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQ_CFG_DIR_CONFIG) + " BIGINT, "
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQ_CFG_DIR_DIRECTION) + " BIGINT, "
+          + "CONSTRAINT " + CommonRepoUtils.escapeConstraintName(CommonRepositorySchemaConstants.CONSTRAINT_SQ_CFG_DIR_CONFIG_NAME)
+            + " FOREIGN KEY (" + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQ_CFG_DIR_CONFIG) + ") REFERENCES "
+              + CommonRepoUtils.getTableName(SCHEMA_SQOOP, CommonRepositorySchemaConstants.TABLE_SQ_CONFIG_NAME) + "("  + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQ_CFG_ID) + "), "
+          + "CONSTRAINT " + CommonRepoUtils.escapeConstraintName(CommonRepositorySchemaConstants.CONSTRAINT_SQ_CFG_DIR_DIRECTION_NAME)
+            + " FOREIGN KEY (" + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQ_CFG_DIR_DIRECTION) + ") REFERENCES "
+              + CommonRepoUtils.getTableName(SCHEMA_SQOOP, CommonRepositorySchemaConstants.TABLE_SQ_DIRECTION_NAME) + "("  + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQD_ID) + ")"
           + ")";
 
   public static final String QUERY_CREATE_TABLE_SQ_INPUT =
-      "CREATE TABLE " + CommonRepoUtils.getTableName(SCHEMA_SQOOP, TABLE_SQ_INPUT_NAME) + " ("
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQI_ID) + " BIGSERIAL PRIMARY KEY NOT NULL, "
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQI_NAME) + " VARCHAR(64), "
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQI_CONFIG) + " BIGINT, "
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQI_INDEX) + " SMALLINT, "
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQI_TYPE) + " VARCHAR(32), "
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQI_STRMASK) + " BOOLEAN, "
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQI_STRLENGTH) + " SMALLINT, "
+      "CREATE TABLE " + CommonRepoUtils.getTableName(SCHEMA_SQOOP, CommonRepositorySchemaConstants.TABLE_SQ_INPUT_NAME) + " ("
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQI_ID) + " BIGSERIAL PRIMARY KEY NOT NULL, "
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQI_NAME) + " VARCHAR(64), "
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQI_CONFIG) + " BIGINT, "
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQI_INDEX) + " SMALLINT, "
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQI_TYPE) + " VARCHAR(32), "
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQI_STRMASK) + " BOOLEAN, "
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQI_STRLENGTH) + " SMALLINT, "
           + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQI_EDITABLE) + " VARCHAR(32), "
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQI_ENUMVALS) + " VARCHAR(100), "
-          + "CONSTRAINT " + CommonRepoUtils.escapeConstraintName(CONSTRAINT_SQI_SQ_CFG_NAME)
-            + " FOREIGN KEY (" + CommonRepoUtils.escapeColumnName(COLUMN_SQI_CONFIG) + ") REFERENCES "
-              + CommonRepoUtils.getTableName(SCHEMA_SQOOP, TABLE_SQ_CONFIG_NAME) + "("  + CommonRepoUtils.escapeColumnName(COLUMN_SQ_CFG_ID) + "), "
-          + "CONSTRAINT " + CommonRepoUtils.escapeConstraintName(CONSTRAINT_SQ_INPUT_UNIQUE_NAME_TYPE_CONFIG)
-            + " UNIQUE (" + CommonRepoUtils.escapeColumnName(COLUMN_SQI_NAME) + ", "
-                          + CommonRepoUtils.escapeColumnName(COLUMN_SQI_TYPE) + ", "
-                          + CommonRepoUtils.escapeColumnName(COLUMN_SQI_CONFIG) + ") "
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQI_ENUMVALS) + " VARCHAR(100), "
+          + "CONSTRAINT " + CommonRepoUtils.escapeConstraintName(CommonRepositorySchemaConstants.CONSTRAINT_SQI_SQ_CFG_NAME)
+            + " FOREIGN KEY (" + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQI_CONFIG) + ") REFERENCES "
+              + CommonRepoUtils.getTableName(SCHEMA_SQOOP, CommonRepositorySchemaConstants.TABLE_SQ_CONFIG_NAME) + "("  + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQ_CFG_ID) + "), "
+          + "CONSTRAINT " + CommonRepoUtils.escapeConstraintName(CommonRepositorySchemaConstants.CONSTRAINT_SQ_INPUT_UNIQUE_NAME_TYPE_CONFIG)
+            + " UNIQUE (" + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQI_NAME) + ", "
+                          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQI_TYPE) + ", "
+                          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQI_CONFIG) + ") "
           + ")";
 
   public static final String QUERY_CREATE_TABLE_SQ_INPUT_RELATION =
@@ -342,124 +340,124 @@ public class PostgresqlSchemaCreateQuery {
           + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQIR_ID) + " BIGSERIAL PRIMARY KEY NOT NULL, "
           + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQIR_PARENT) + " BIGINT, "
           + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQIR_CHILD) + " BIGINT, "
-          + "CONSTRAINT " + CommonRepoUtils.escapeConstraintName(CONSTRAINT_SQIR_PARENT_NAME)
+          + "CONSTRAINT " + CommonRepoUtils.escapeConstraintName(CommonRepositorySchemaConstants.CONSTRAINT_SQIR_PARENT_NAME)
             + " FOREIGN KEY (" + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQIR_PARENT) + ") REFERENCES "
-              + CommonRepoUtils.getTableName(SCHEMA_SQOOP, TABLE_SQ_INPUT_NAME) + "("  + CommonRepoUtils.escapeColumnName(COLUMN_SQI_ID) + "), "
-          + "CONSTRAINT " + CommonRepoUtils.escapeConstraintName(CONSTRAINT_SQIR_CHILD_NAME)
+              + CommonRepoUtils.getTableName(SCHEMA_SQOOP, CommonRepositorySchemaConstants.TABLE_SQ_INPUT_NAME) + "("  + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQI_ID) + "), "
+          + "CONSTRAINT " + CommonRepoUtils.escapeConstraintName(CommonRepositorySchemaConstants.CONSTRAINT_SQIR_CHILD_NAME)
             + " FOREIGN KEY (" + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQIR_CHILD) + ") REFERENCES "
-              + CommonRepoUtils.getTableName(SCHEMA_SQOOP, TABLE_SQ_INPUT_NAME) + "("  + CommonRepoUtils.escapeColumnName(COLUMN_SQI_ID) + ")"
+              + CommonRepoUtils.getTableName(SCHEMA_SQOOP, CommonRepositorySchemaConstants.TABLE_SQ_INPUT_NAME) + "("  + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQI_ID) + ")"
           + ")";
 
   public static final String QUERY_CREATE_TABLE_SQ_LINK =
-      "CREATE TABLE " + CommonRepoUtils.getTableName(SCHEMA_SQOOP, TABLE_SQ_LINK_NAME) + " ("
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQ_LNK_ID) + " BIGSERIAL PRIMARY KEY NOT NULL, "
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQ_LNK_CONFIGURABLE) + " BIGINT, "
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQ_LNK_NAME)  + " VARCHAR(32) CONSTRAINT "
-            + CommonRepoUtils.escapeConstraintName(CONSTRAINT_SQ_LNK_NAME_UNIQUE_NAME) +  " UNIQUE, "
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQ_LNK_CREATION_DATE) + " TIMESTAMP, "
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQ_LNK_CREATION_USER) + " VARCHAR(32) DEFAULT NULL, "
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQ_LNK_UPDATE_DATE) + " TIMESTAMP, "
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQ_LNK_UPDATE_USER) + " VARCHAR(32) DEFAULT NULL, "
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQ_LNK_ENABLED) + " BOOLEAN DEFAULT TRUE, "
-          + "CONSTRAINT " + CommonRepoUtils.escapeConstraintName(CONSTRAINT_SQ_LNK_SQC_NAME)
-            + " FOREIGN KEY (" + CommonRepoUtils.escapeColumnName(COLUMN_SQ_LNK_CONFIGURABLE) + ") REFERENCES "
-              + CommonRepoUtils.getTableName(SCHEMA_SQOOP, TABLE_SQ_CONFIGURABLE_NAME) + "("  + CommonRepoUtils.escapeColumnName(COLUMN_SQC_ID) + ")"
+      "CREATE TABLE " + CommonRepoUtils.getTableName(SCHEMA_SQOOP, CommonRepositorySchemaConstants.TABLE_SQ_LINK_NAME) + " ("
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQ_LNK_ID) + " BIGSERIAL PRIMARY KEY NOT NULL, "
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQ_LNK_CONFIGURABLE) + " BIGINT, "
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQ_LNK_NAME)  + " VARCHAR(32) CONSTRAINT "
+            + CommonRepoUtils.escapeConstraintName(CommonRepositorySchemaConstants.CONSTRAINT_SQ_LNK_NAME_UNIQUE_NAME) +  " UNIQUE, "
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQ_LNK_CREATION_DATE) + " TIMESTAMP, "
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQ_LNK_CREATION_USER) + " VARCHAR(32) DEFAULT NULL, "
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQ_LNK_UPDATE_DATE) + " TIMESTAMP, "
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQ_LNK_UPDATE_USER) + " VARCHAR(32) DEFAULT NULL, "
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQ_LNK_ENABLED) + " BOOLEAN DEFAULT TRUE, "
+          + "CONSTRAINT " + CommonRepoUtils.escapeConstraintName(CommonRepositorySchemaConstants.CONSTRAINT_SQ_LNK_SQC_NAME)
+            + " FOREIGN KEY (" + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQ_LNK_CONFIGURABLE) + ") REFERENCES "
+              + CommonRepoUtils.getTableName(SCHEMA_SQOOP, CommonRepositorySchemaConstants.TABLE_SQ_CONFIGURABLE_NAME) + "("  + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQC_ID) + ")"
           + ")";
 
   public static final String QUERY_CREATE_TABLE_SQ_JOB =
-      "CREATE TABLE " + CommonRepoUtils.getTableName(SCHEMA_SQOOP, TABLE_SQ_JOB_NAME) + " ("
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQB_ID) + " BIGSERIAL PRIMARY KEY NOT NULL, "
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQB_FROM_LINK) + " BIGINT, "
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQB_TO_LINK) + " BIGINT, "
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQB_NAME) + " VARCHAR(64) CONSTRAINT "
-            + CommonRepoUtils.escapeConstraintName(CONSTRAINT_SQB_NAME_UNIQUE_NAME) +  " UNIQUE, "
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQB_CREATION_DATE) + " TIMESTAMP, "
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQB_CREATION_USER) + " VARCHAR(32) DEFAULT NULL, "
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQB_UPDATE_DATE) + " TIMESTAMP, "
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQB_UPDATE_USER) + " VARCHAR(32) DEFAULT NULL, "
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQB_ENABLED) + " BOOLEAN DEFAULT TRUE, "
-          + "CONSTRAINT " + CommonRepoUtils.escapeConstraintName(CONSTRAINT_SQB_SQ_LNK_FROM_NAME)
-            + " FOREIGN KEY (" + CommonRepoUtils.escapeColumnName(COLUMN_SQB_FROM_LINK) + ") REFERENCES "
-              + CommonRepoUtils.getTableName(SCHEMA_SQOOP, TABLE_SQ_LINK_NAME) + "("  + CommonRepoUtils.escapeColumnName(COLUMN_SQ_LNK_ID) + "), "
-          + "CONSTRAINT " + CommonRepoUtils.escapeConstraintName(CONSTRAINT_SQB_SQ_LNK_TO_NAME)
-            + " FOREIGN KEY (" + CommonRepoUtils.escapeColumnName(COLUMN_SQB_TO_LINK) + ") REFERENCES "
-              + CommonRepoUtils.getTableName(SCHEMA_SQOOP, TABLE_SQ_LINK_NAME) + "("  + CommonRepoUtils.escapeColumnName(COLUMN_SQ_LNK_ID) + ")"
+      "CREATE TABLE " + CommonRepoUtils.getTableName(SCHEMA_SQOOP, CommonRepositorySchemaConstants.TABLE_SQ_JOB_NAME) + " ("
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQB_ID) + " BIGSERIAL PRIMARY KEY NOT NULL, "
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQB_FROM_LINK) + " BIGINT, "
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQB_TO_LINK) + " BIGINT, "
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQB_NAME) + " VARCHAR(64) CONSTRAINT "
+            + CommonRepoUtils.escapeConstraintName(CommonRepositorySchemaConstants.CONSTRAINT_SQB_NAME_UNIQUE_NAME) +  " UNIQUE, "
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQB_CREATION_DATE) + " TIMESTAMP, "
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQB_CREATION_USER) + " VARCHAR(32) DEFAULT NULL, "
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQB_UPDATE_DATE) + " TIMESTAMP, "
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQB_UPDATE_USER) + " VARCHAR(32) DEFAULT NULL, "
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQB_ENABLED) + " BOOLEAN DEFAULT TRUE, "
+          + "CONSTRAINT " + CommonRepoUtils.escapeConstraintName(CommonRepositorySchemaConstants.CONSTRAINT_SQB_SQ_LNK_FROM_NAME)
+            + " FOREIGN KEY (" + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQB_FROM_LINK) + ") REFERENCES "
+              + CommonRepoUtils.getTableName(SCHEMA_SQOOP, CommonRepositorySchemaConstants.TABLE_SQ_LINK_NAME) + "("  + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQ_LNK_ID) + "), "
+          + "CONSTRAINT " + CommonRepoUtils.escapeConstraintName(CommonRepositorySchemaConstants.CONSTRAINT_SQB_SQ_LNK_TO_NAME)
+            + " FOREIGN KEY (" + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQB_TO_LINK) + ") REFERENCES "
+              + CommonRepoUtils.getTableName(SCHEMA_SQOOP, CommonRepositorySchemaConstants.TABLE_SQ_LINK_NAME) + "("  + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQ_LNK_ID) + ")"
           + ")";
 
   public static final String QUERY_CREATE_TABLE_SQ_LINK_INPUT =
-      "CREATE TABLE " + CommonRepoUtils.getTableName(SCHEMA_SQOOP, TABLE_SQ_LINK_INPUT_NAME) + " ("
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQ_LNKI_LINK) + " BIGINT, "
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQ_LNKI_INPUT) + " BIGINT, "
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQ_LNKI_VALUE) + " VARCHAR, "
-          + "PRIMARY KEY (" + CommonRepoUtils.escapeColumnName(COLUMN_SQ_LNKI_LINK) + ", " + CommonRepoUtils.escapeColumnName(COLUMN_SQ_LNKI_INPUT) + "), "
-          + "CONSTRAINT " + CommonRepoUtils.escapeConstraintName(CONSTRAINT_SQ_LNKI_SQ_LNK_NAME)
-            + " FOREIGN KEY (" + CommonRepoUtils.escapeColumnName(COLUMN_SQ_LNKI_LINK) + ") REFERENCES "
-              + CommonRepoUtils.getTableName(SCHEMA_SQOOP, TABLE_SQ_LINK_NAME) + "("  + CommonRepoUtils.escapeColumnName(COLUMN_SQ_LNK_ID) + "), "
-          + "CONSTRAINT " + CommonRepoUtils.escapeConstraintName(CONSTRAINT_SQ_LNKI_SQI_NAME)
-            + " FOREIGN KEY (" + CommonRepoUtils.escapeColumnName(COLUMN_SQ_LNKI_INPUT) + ") REFERENCES "
-              + CommonRepoUtils.getTableName(SCHEMA_SQOOP, TABLE_SQ_INPUT_NAME) + "("  + CommonRepoUtils.escapeColumnName(COLUMN_SQI_ID) + ")"
+      "CREATE TABLE " + CommonRepoUtils.getTableName(SCHEMA_SQOOP, CommonRepositorySchemaConstants.TABLE_SQ_LINK_INPUT_NAME) + " ("
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQ_LNKI_LINK) + " BIGINT, "
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQ_LNKI_INPUT) + " BIGINT, "
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQ_LNKI_VALUE) + " VARCHAR, "
+          + "PRIMARY KEY (" + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQ_LNKI_LINK) + ", " + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQ_LNKI_INPUT) + "), "
+          + "CONSTRAINT " + CommonRepoUtils.escapeConstraintName(CommonRepositorySchemaConstants.CONSTRAINT_SQ_LNKI_SQ_LNK_NAME)
+            + " FOREIGN KEY (" + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQ_LNKI_LINK) + ") REFERENCES "
+              + CommonRepoUtils.getTableName(SCHEMA_SQOOP, CommonRepositorySchemaConstants.TABLE_SQ_LINK_NAME) + "("  + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQ_LNK_ID) + "), "
+          + "CONSTRAINT " + CommonRepoUtils.escapeConstraintName(CommonRepositorySchemaConstants.CONSTRAINT_SQ_LNKI_SQI_NAME)
+            + " FOREIGN KEY (" + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQ_LNKI_INPUT) + ") REFERENCES "
+              + CommonRepoUtils.getTableName(SCHEMA_SQOOP, CommonRepositorySchemaConstants.TABLE_SQ_INPUT_NAME) + "("  + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQI_ID) + ")"
           + ")";
 
   public static final String QUERY_CREATE_TABLE_SQ_JOB_INPUT =
-      "CREATE TABLE " + CommonRepoUtils.getTableName(SCHEMA_SQOOP, TABLE_SQ_JOB_INPUT_NAME) + " ("
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQBI_JOB) + " BIGINT, "
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQBI_INPUT) + " BIGINT, "
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQBI_VALUE) + " VARCHAR(1000), "
-          + "PRIMARY KEY (" + CommonRepoUtils.escapeColumnName(COLUMN_SQBI_JOB) + ", " + CommonRepoUtils.escapeColumnName(COLUMN_SQBI_INPUT) + "), "
-          + "CONSTRAINT " + CommonRepoUtils.escapeConstraintName(CONSTRAINT_SQBI_SQB_NAME)
-            + " FOREIGN KEY (" + CommonRepoUtils.escapeColumnName(COLUMN_SQBI_JOB) + ") REFERENCES "
-              + CommonRepoUtils.getTableName(SCHEMA_SQOOP, TABLE_SQ_JOB_NAME) + "("  + CommonRepoUtils.escapeColumnName(COLUMN_SQB_ID) + "), "
-          + "CONSTRAINT " + CommonRepoUtils.escapeConstraintName(CONSTRAINT_SQBI_SQI_NAME)
-            + " FOREIGN KEY (" + CommonRepoUtils.escapeColumnName(COLUMN_SQBI_INPUT) + ") REFERENCES "
-              + CommonRepoUtils.getTableName(SCHEMA_SQOOP, TABLE_SQ_INPUT_NAME) + "("  + CommonRepoUtils.escapeColumnName(COLUMN_SQI_ID) + ")"
+      "CREATE TABLE " + CommonRepoUtils.getTableName(SCHEMA_SQOOP, CommonRepositorySchemaConstants.TABLE_SQ_JOB_INPUT_NAME) + " ("
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQBI_JOB) + " BIGINT, "
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQBI_INPUT) + " BIGINT, "
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQBI_VALUE) + " VARCHAR(1000), "
+          + "PRIMARY KEY (" + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQBI_JOB) + ", " + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQBI_INPUT) + "), "
+          + "CONSTRAINT " + CommonRepoUtils.escapeConstraintName(CommonRepositorySchemaConstants.CONSTRAINT_SQBI_SQB_NAME)
+            + " FOREIGN KEY (" + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQBI_JOB) + ") REFERENCES "
+              + CommonRepoUtils.getTableName(SCHEMA_SQOOP, CommonRepositorySchemaConstants.TABLE_SQ_JOB_NAME) + "("  + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQB_ID) + "), "
+          + "CONSTRAINT " + CommonRepoUtils.escapeConstraintName(CommonRepositorySchemaConstants.CONSTRAINT_SQBI_SQI_NAME)
+            + " FOREIGN KEY (" + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQBI_INPUT) + ") REFERENCES "
+              + CommonRepoUtils.getTableName(SCHEMA_SQOOP, CommonRepositorySchemaConstants.TABLE_SQ_INPUT_NAME) + "("  + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQI_ID) + ")"
           + ")";
 
   public static final String QUERY_CREATE_TABLE_SQ_SUBMISSION =
-      "CREATE TABLE " + CommonRepoUtils.getTableName(SCHEMA_SQOOP, TABLE_SQ_SUBMISSION_NAME) + " ("
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQS_ID) + " BIGSERIAL PRIMARY KEY NOT NULL, "
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQS_JOB) + " BIGINT, "
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQS_STATUS) + " VARCHAR(20), "
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQS_CREATION_DATE) + " TIMESTAMP, "
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQS_CREATION_USER) + " VARCHAR(32) DEFAULT NULL, "
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQS_UPDATE_DATE) + " TIMESTAMP, "
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQS_UPDATE_USER) + " VARCHAR(32) DEFAULT NULL, "
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQS_EXTERNAL_ID) + " VARCHAR(50), "
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQS_EXTERNAL_LINK) + " VARCHAR(150), "
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQS_ERROR_SUMMARY) + " VARCHAR(150), "
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQS_ERROR_DETAILS) + " VARCHAR(750), "
-          + "CONSTRAINT " + CommonRepoUtils.escapeConstraintName(CONSTRAINT_SQS_SQB_NAME)
-            + " FOREIGN KEY (" + CommonRepoUtils.escapeColumnName(COLUMN_SQS_JOB) + ") REFERENCES "
-              + CommonRepoUtils.getTableName(SCHEMA_SQOOP, TABLE_SQ_JOB_NAME) + "("  + CommonRepoUtils.escapeColumnName(COLUMN_SQB_ID) + ") ON DELETE CASCADE"
+      "CREATE TABLE " + CommonRepoUtils.getTableName(SCHEMA_SQOOP, CommonRepositorySchemaConstants.TABLE_SQ_SUBMISSION_NAME) + " ("
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQS_ID) + " BIGSERIAL PRIMARY KEY NOT NULL, "
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQS_JOB) + " BIGINT, "
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQS_STATUS) + " VARCHAR(20), "
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQS_CREATION_DATE) + " TIMESTAMP, "
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQS_CREATION_USER) + " VARCHAR(32) DEFAULT NULL, "
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQS_UPDATE_DATE) + " TIMESTAMP, "
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQS_UPDATE_USER) + " VARCHAR(32) DEFAULT NULL, "
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQS_EXTERNAL_ID) + " VARCHAR(50), "
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQS_EXTERNAL_LINK) + " VARCHAR(150), "
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQS_ERROR_SUMMARY) + " VARCHAR(150), "
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQS_ERROR_DETAILS) + " VARCHAR(750), "
+          + "CONSTRAINT " + CommonRepoUtils.escapeConstraintName(CommonRepositorySchemaConstants.CONSTRAINT_SQS_SQB_NAME)
+            + " FOREIGN KEY (" + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQS_JOB) + ") REFERENCES "
+              + CommonRepoUtils.getTableName(SCHEMA_SQOOP, CommonRepositorySchemaConstants.TABLE_SQ_JOB_NAME) + "("  + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQB_ID) + ") ON DELETE CASCADE"
           + ")";
 
   public static final String QUERY_CREATE_TABLE_SQ_COUNTER_GROUP =
-      "CREATE TABLE " + CommonRepoUtils.getTableName(SCHEMA_SQOOP, TABLE_SQ_COUNTER_GROUP_NAME) + " ("
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQG_ID) + " BIGSERIAL PRIMARY KEY NOT NULL, "
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQG_NAME) + " VARCHAR(75) UNIQUE"
+      "CREATE TABLE " + CommonRepoUtils.getTableName(SCHEMA_SQOOP, CommonRepositorySchemaConstants.TABLE_SQ_COUNTER_GROUP_NAME) + " ("
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQG_ID) + " BIGSERIAL PRIMARY KEY NOT NULL, "
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQG_NAME) + " VARCHAR(75) UNIQUE"
           + ")";
 
   public static final String QUERY_CREATE_TABLE_SQ_COUNTER =
-      "CREATE TABLE " + CommonRepoUtils.getTableName(SCHEMA_SQOOP, TABLE_SQ_COUNTER_NAME) + " ("
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQR_ID) + " BIGSERIAL PRIMARY KEY NOT NULL, "
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQR_NAME) + " VARCHAR(75) UNIQUE"
+      "CREATE TABLE " + CommonRepoUtils.getTableName(SCHEMA_SQOOP, CommonRepositorySchemaConstants.TABLE_SQ_COUNTER_NAME) + " ("
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQR_ID) + " BIGSERIAL PRIMARY KEY NOT NULL, "
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQR_NAME) + " VARCHAR(75) UNIQUE"
           + ")";
 
   public static final String QUERY_CREATE_TABLE_SQ_COUNTER_SUBMISSION =
-      "CREATE TABLE " + CommonRepoUtils.getTableName(SCHEMA_SQOOP, TABLE_SQ_COUNTER_SUBMISSION_NAME) + " ("
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQRS_GROUP) + " BIGINT, "
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQRS_COUNTER) + " BIGINT, "
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQRS_SUBMISSION) + " BIGINT, "
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQRS_VALUE) + " BIGINT, "
-          + "PRIMARY KEY (" + CommonRepoUtils.escapeColumnName(COLUMN_SQRS_GROUP) + ", " + CommonRepoUtils.escapeColumnName(COLUMN_SQRS_COUNTER) + ", " + CommonRepoUtils.escapeColumnName(COLUMN_SQRS_SUBMISSION) + "), "
-          + "CONSTRAINT " + CommonRepoUtils.escapeConstraintName(CONSTRAINT_SQRS_SQG_NAME)
-            + " FOREIGN KEY (" + CommonRepoUtils.escapeColumnName(COLUMN_SQRS_GROUP) + ") REFERENCES "
-              + CommonRepoUtils.getTableName(SCHEMA_SQOOP, TABLE_SQ_COUNTER_GROUP_NAME) + "("  + CommonRepoUtils.escapeColumnName(COLUMN_SQG_ID) + "), "
-          + "CONSTRAINT " + CommonRepoUtils.escapeConstraintName(CONSTRAINT_SQRS_SQR_NAME)
-            + " FOREIGN KEY (" + CommonRepoUtils.escapeColumnName(COLUMN_SQRS_COUNTER) + ") REFERENCES "
-              + CommonRepoUtils.getTableName(SCHEMA_SQOOP, TABLE_SQ_COUNTER_NAME) + "("  + CommonRepoUtils.escapeColumnName(COLUMN_SQR_ID) + "), "
-          + "CONSTRAINT " + CommonRepoUtils.escapeConstraintName(CONSTRAINT_SQRS_SQS_NAME)
-            + " FOREIGN KEY (" + CommonRepoUtils.escapeColumnName(COLUMN_SQRS_SUBMISSION) + ") REFERENCES "
-              + CommonRepoUtils.getTableName(SCHEMA_SQOOP, TABLE_SQ_SUBMISSION_NAME) + "("  + CommonRepoUtils.escapeColumnName(COLUMN_SQS_ID) + ") ON DELETE CASCADE"
+      "CREATE TABLE " + CommonRepoUtils.getTableName(SCHEMA_SQOOP, CommonRepositorySchemaConstants.TABLE_SQ_COUNTER_SUBMISSION_NAME) + " ("
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQRS_GROUP) + " BIGINT, "
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQRS_COUNTER) + " BIGINT, "
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQRS_SUBMISSION) + " BIGINT, "
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQRS_VALUE) + " BIGINT, "
+          + "PRIMARY KEY (" + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQRS_GROUP) + ", " + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQRS_COUNTER) + ", " + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQRS_SUBMISSION) + "), "
+          + "CONSTRAINT " + CommonRepoUtils.escapeConstraintName(CommonRepositorySchemaConstants.CONSTRAINT_SQRS_SQG_NAME)
+            + " FOREIGN KEY (" + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQRS_GROUP) + ") REFERENCES "
+              + CommonRepoUtils.getTableName(SCHEMA_SQOOP, CommonRepositorySchemaConstants.TABLE_SQ_COUNTER_GROUP_NAME) + "("  + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQG_ID) + "), "
+          + "CONSTRAINT " + CommonRepoUtils.escapeConstraintName(CommonRepositorySchemaConstants.CONSTRAINT_SQRS_SQR_NAME)
+            + " FOREIGN KEY (" + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQRS_COUNTER) + ") REFERENCES "
+              + CommonRepoUtils.getTableName(SCHEMA_SQOOP, CommonRepositorySchemaConstants.TABLE_SQ_COUNTER_NAME) + "("  + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQR_ID) + "), "
+          + "CONSTRAINT " + CommonRepoUtils.escapeConstraintName(CommonRepositorySchemaConstants.CONSTRAINT_SQRS_SQS_NAME)
+            + " FOREIGN KEY (" + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQRS_SUBMISSION) + ") REFERENCES "
+              + CommonRepoUtils.getTableName(SCHEMA_SQOOP, CommonRepositorySchemaConstants.TABLE_SQ_SUBMISSION_NAME) + "("  + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQS_ID) + ") ON DELETE CASCADE"
           + ")";
 
   private PostgresqlSchemaCreateQuery() {

http://git-wip-us.apache.org/repos/asf/sqoop/blob/cfe27340/repository/repository-postgresql/src/main/java/org/apache/sqoop/repository/postgresql/PostgresqlSchemaQuery.java
----------------------------------------------------------------------
diff --git a/repository/repository-postgresql/src/main/java/org/apache/sqoop/repository/postgresql/PostgresqlSchemaQuery.java b/repository/repository-postgresql/src/main/java/org/apache/sqoop/repository/postgresql/PostgresqlSchemaQuery.java
index 3e83149..cfbfc36 100644
--- a/repository/repository-postgresql/src/main/java/org/apache/sqoop/repository/postgresql/PostgresqlSchemaQuery.java
+++ b/repository/repository-postgresql/src/main/java/org/apache/sqoop/repository/postgresql/PostgresqlSchemaQuery.java
@@ -18,8 +18,7 @@
 package org.apache.sqoop.repository.postgresql;
 
 import org.apache.sqoop.repository.common.CommonRepoUtils;
-
-import static org.apache.sqoop.repository.postgresql.PostgresqlSchemaConstants.*;
+import org.apache.sqoop.repository.common.CommonRepositorySchemaConstants;
 
 /**
  * DML for PostgreSQL repository.
@@ -28,23 +27,23 @@ public class PostgresqlSchemaQuery {
 
   public static final String STMT_SELECT_SYSTEM =
       "SELECT "
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQM_VALUE)
-          + " FROM " + CommonRepoUtils.getTableName(SCHEMA_SQOOP, TABLE_SQ_SYSTEM_NAME)
-          + " WHERE " + CommonRepoUtils.escapeColumnName(COLUMN_SQM_KEY) + " = ?";
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQM_VALUE)
+          + " FROM " + CommonRepoUtils.getTableName(CommonRepositorySchemaConstants.SCHEMA_SQOOP, CommonRepositorySchemaConstants.TABLE_SQ_SYSTEM_NAME)
+          + " WHERE " + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQM_KEY) + " = ?";
 
   public static final String STMT_DELETE_SYSTEM =
-      "DELETE FROM "  + CommonRepoUtils.getTableName(SCHEMA_SQOOP, TABLE_SQ_SYSTEM_NAME)
-          + " WHERE " + CommonRepoUtils.escapeColumnName(COLUMN_SQM_KEY) + " = ?";
+      "DELETE FROM "  + CommonRepoUtils.getTableName(CommonRepositorySchemaConstants.SCHEMA_SQOOP, CommonRepositorySchemaConstants.TABLE_SQ_SYSTEM_NAME)
+          + " WHERE " + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQM_KEY) + " = ?";
 
   public static final String STMT_INSERT_SYSTEM =
-      "INSERT INTO " + CommonRepoUtils.getTableName(SCHEMA_SQOOP, TABLE_SQ_SYSTEM_NAME) + "("
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQM_KEY) + ", "
-          + CommonRepoUtils.escapeColumnName(COLUMN_SQM_VALUE) + ") "
+      "INSERT INTO " + CommonRepoUtils.getTableName(CommonRepositorySchemaConstants.SCHEMA_SQOOP, CommonRepositorySchemaConstants.TABLE_SQ_SYSTEM_NAME) + "("
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQM_KEY) + ", "
+          + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQM_VALUE) + ") "
           + "VALUES(?, ?)";
 
   public static final String STMT_INSERT_DIRECTION =
-      "INSERT INTO " + CommonRepoUtils.getTableName(SCHEMA_SQOOP, TABLE_SQ_DIRECTION_NAME)
-          + " (" + CommonRepoUtils.escapeColumnName(COLUMN_SQD_NAME)+ ") VALUES (?)";
+      "INSERT INTO " + CommonRepoUtils.getTableName(CommonRepositorySchemaConstants.SCHEMA_SQOOP, CommonRepositorySchemaConstants.TABLE_SQ_DIRECTION_NAME)
+          + " (" + CommonRepoUtils.escapeColumnName(CommonRepositorySchemaConstants.COLUMN_SQD_NAME)+ ") VALUES (?)";
 
   private PostgresqlSchemaQuery() {
     // Disable explicit object creation


Mime
View raw message