Buggy code:
public class MainDao { protected static String host ; protected static String port ; protected static String db ; protected static String user ; protected static String password ; protected static Boolean useSsl ; protected static String binFolder ; protected static String giswaterUsersFolder ; private static Connection connectionPostgis ; private static String waterSoftware ; private static String schema ; private static boolean isConnected = false ; private static String updatesFolder ; private static String giswaterVersion ; private static String postgreVersion ; private static String postgisVersion ; private static Boolean updateSchemaVersion = true ; private static HashMap < String , Integer > schemaMap ; private static HashMap < String , Integer > updateMap ; private static final String FOLDER_NAME = "giswater" + ( File . separator ) ; private static final String INIT_DB = "giswater_ddb" ; private static final String DEFAULT_DB = "postgres" ; private static final String INIT_GISWATER_DDB = "init_giswater_ddb.sql" ; private static final String TABLE_EPANET = "inp_demand" ; private static final String TABLE_EPASWMM = "inp_divider" ; private static final String TABLE_HECRAS = "banks" ; private static final Integer NUMBER_OF_ATTEMPTS = 3 ; public static String getDb ( ) { } public static String getBinFolder ( ) { } public static String getHost ( ) { } public static String getPort ( ) { } public static String getUser ( ) { } public static String getPassword ( ) { } public static void setConnectionParams ( String host , String port , String db , String user , String password ) { } public static Connection getConnectionPostgis ( ) { } public static String getWaterSoftware ( ) { } public static void setWaterSoftware ( String param ) { } public static boolean isConnected ( ) { } public static void setConnected ( boolean connected ) { } public static String getSchema ( ) { } public static void setSchema ( String param ) { } public static String getGiswaterUsersFolder ( ) { } public static String getGiswaterVersion ( ) { } public static String getPostgreVersion ( ) { } public static String getPostgisVersion ( ) { } public static boolean configIni ( String versionCode ) { } private static void setLocale ( ) { Locale locale = new Locale ( "en" , "EN" ) ; String language = PropertiesDao . getPropertiesFile ( ) . get ( "LANGUAGE" , "en" ) ; if ( language . equals ( "es" ) ) { locale = new Locale ( "es" , "ES" ) ; } else if ( language . equals ( "pt" ) ) { locale = new Locale ( "pt" , "PT" ) ; } else if ( language . equals ( "pt_BR" ) ) { <START_BUG> locale = new Locale ( "pt_BR" , "PT_BR" ) ; <END_BUG> } Utils . setLocale ( locale ) ; } public static boolean setBinFolder ( ) { } protected static boolean getConnectionParameters ( ) { } private static boolean commonSteps ( ) { } public static boolean silenceConnection ( ) { } public static boolean initializeDatabase ( ) { } private static boolean initDatabase ( ) { } public static void rollback ( ) { } public static boolean setConnectionPostgis ( String host , String port , String db , String user , String password , boolean useSsl , boolean showError ) { } public static void closeConnectionPostgis ( ) { } public static boolean executeUpdateSql ( String sql ) { } public static boolean executeUpdateSql ( String sql , boolean commit ) { } public static boolean executeUpdateSql ( String sql , boolean commit , boolean showError ) { } public static boolean executeSql ( String sql ) { } public static boolean executeSql ( String sql , boolean commit ) { } public static Exception executeSql ( String sql , boolean commit , String dummy ) { } public static boolean checkColumn ( ResultSet rs , String columnName ) { } public static boolean checkTableHasData ( String schemaName , String tableName ) { } private static boolean checkQuery ( String sql ) { } public static String queryToString ( String sql ) { } public static String queryToString ( String sql , boolean showError ) { } public static boolean checkTable ( String tableName ) { } public static boolean checkTable ( String schemaName , String tableName ) { } public static boolean checkView ( String viewName ) { } public static boolean checkView ( String schemaName , String viewName ) { } public static boolean checkDatabase ( String dbName ) { } public static boolean checkSchema ( String schemaName ) { } public static String checkPostgreVersion ( ) { } public static String checkPostgisVersion ( ) { } public static boolean checkSrid ( Integer srid ) { } private static boolean checkSoftwareSchema ( String software , String schemaName ) { } public static Vector < String > getSchemas ( ) { } public static Vector < String > getSchemas ( String software ) { } public static ResultSet getResultset ( Connection connection , String sql , boolean showError , int type , int concurrency ) { } public static ResultSet getResultset ( Connection connection , String sql , boolean showError ) { } public static ResultSet getResultset ( String sql , boolean showError ) { } public static ResultSet getResultset ( String sql ) { } public static ResultSet getTableResultset ( Connection connection , String table , String fields , String fieldOrderBy ) { } public static ResultSet getTableResultset ( String table , String fields , String fieldOrderBy ) { } public static ResultSet getTableResultset ( String table , String fields ) { } public static ResultSet getTableResultset ( String table ) { } public static ResultSet getRaingageResultset ( String table ) { } public static Vector < String > getTable ( String table , String schemaParam ) { } public static Vector < String > getTable ( String tableName , String schemaName , boolean addBlank , String fields ) { }

Fix:
locale = new Locale ( "pt" , "BR" ) ;