/** * Create a table with an 'id' column of type varchar(20) */ private void createIdVarcharTable(String tableName, int insertRows) throws SQLException { SqoopOptions options = new SqoopOptions(); options.setConnectString(SOURCE_DB_URL); HsqldbManager manager = new HsqldbManager(options); Connection c = manager.getConnection(); PreparedStatement s = null; try { s = c.prepareStatement("CREATE TABLE " + manager.escapeTableName(tableName) + "(id varchar(20) NOT NULL)"); s.executeUpdate(); c.commit(); insertIdVarcharRows(tableName, 0, insertRows); } finally { s.close(); } }