Class dblook

java.lang.Object
org.apache.derby.tools.dblook

public final class dblook extends Object
  • Field Details

    • DB2_MAX_NUMBER_OF_TABLES

      private static final int DB2_MAX_NUMBER_OF_TABLES
      See Also:
    • conn

      private Connection conn
    • getColNameFromNumberQuery

      private static PreparedStatement getColNameFromNumberQuery
    • schemaMap

      private static HashMap<String,String> schemaMap
    • tableIdToNameMap

      private static HashMap<String,String> tableIdToNameMap
    • sourceDBUrl

      private static String sourceDBUrl
    • ddlFileName

      private static String ddlFileName
    • stmtDelimiter

      private static String stmtDelimiter
    • appendLogs

      private static boolean appendLogs
    • tableList

      private static ArrayList<String> tableList
    • schemaParam

      private static String schemaParam
    • targetSchema

      private static String targetSchema
    • skipViews

      private static boolean skipViews
    • verbose

      private static boolean verbose
    • sourceDBName

      private static String sourceDBName
    • lookLogName

      private static String lookLogName
    • langUtil

      private static LocalizedResource langUtil
    • sqlAuthorization

      private static boolean sqlAuthorization
    • ignorableSchemaNames

      private static final String[] ignorableSchemaNames
  • Constructor Details

  • Method Details

    • main

      public static void main(String[] args)
    • initState

      private void initState()
    • parseArgs

      private boolean parseArgs(String[] args)
    • loadParam

      private int loadParam(String[] args, int start)
    • loadDriver

      private boolean loadDriver()
    • extractDBNameFromUrl

      private String extractDBNameFromUrl(String dbUrl)
    • extractTableNamesFromList

      private int extractTableNamesFromList(String[] args, int start)
    • showVariables

      private void showVariables()
    • go

      private void go() throws Exception
      Throws:
      Exception
    • prepForDump

      private void prepForDump() throws Exception
      Throws:
      Exception
    • getColumnListFromDescription

      public static String getColumnListFromDescription(String tableId, String description) throws SQLException
      Throws:
      SQLException
    • getColNameFromNumber

      public static String getColNameFromNumber(String tableId, int colNum) throws SQLException
      Throws:
      SQLException
    • addQuotes

      public static String addQuotes(String name)
    • addSingleQuotes

      public static String addSingleQuotes(String name)
    • stripQuotes

      public static String stripQuotes(String quotedName)
    • isExcludedTable

      public static boolean isExcludedTable(String tableName)
    • isIgnorableSchema

      public static boolean isIgnorableSchema(String schemaName)
    • stringContainsTargetTable

      public static boolean stringContainsTargetTable(String str)
    • partOfWord

      private static boolean partOfWord(String str, int pos, int nameLen, int strLen)
    • expandDoubleQuotes

      public static String expandDoubleQuotes(String name)
    • unExpandDoubleQuotes

      public static String unExpandDoubleQuotes(String name)
      inverse of expandDoubleQuotes
    • lookupSchemaId

      public static String lookupSchemaId(String schemaId)
    • lookupTableId

      public static String lookupTableId(String tableId)
    • writeVerboseOutput

      public static void writeVerboseOutput(String key, String value)
    • lookupMessage

      public static String lookupMessage(String key)
    • lookupMessage

      public static String lookupMessage(String key, String[] vals)
    • removeNewlines

      public static String removeNewlines(String str)
    • atVersion

      private static boolean atVersion(Connection conn, int major, int minor) throws SQLException
      Return true if we are at 10.6 or later.
      Throws:
      SQLException