IDEMPIERE-568 Review proper closing of JDBC statements and resultsets
This commit is contained in:
parent
65a9dc9adc
commit
b3ac2521a1
|
@ -138,7 +138,9 @@ public class TableCreateColumns extends SvrProcess
|
|||
{
|
||||
// globalqss 2005-10-25
|
||||
// ResultSet rs = md.getTables(catalog, schema, null, null);
|
||||
ResultSet rs;
|
||||
ResultSet rs = null;
|
||||
ResultSet rsC = null;
|
||||
try {
|
||||
if (DB.isPostgreSQL())
|
||||
rs = md.getTables(catalog, schema, null, new String [] {"TABLE", "VIEW"});
|
||||
else
|
||||
|
@ -187,9 +189,17 @@ public class TableCreateColumns extends SvrProcess
|
|||
if (DB.isPostgreSQL())
|
||||
tableName = tableName.toLowerCase();
|
||||
// end globalqss 2005-10-24
|
||||
ResultSet rsC = md.getColumns(catalog, schema, tableName, null);
|
||||
rsC = md.getColumns(catalog, schema, tableName, null);
|
||||
addTableColumn(rsC, table);
|
||||
}
|
||||
} catch (Exception e) {
|
||||
throw e;
|
||||
} finally {
|
||||
DB.close(rs);
|
||||
rs = null;
|
||||
DB.close(rsC);
|
||||
rsC = null;
|
||||
}
|
||||
} // addTable
|
||||
|
||||
|
||||
|
|
Loading…
Reference in New Issue