Skip to content

Commit

Permalink
fix: Default values on other window.
Browse files Browse the repository at this point in the history
  • Loading branch information
EdwinBetanc0urt committed Jan 17, 2025
1 parent 36d02f4 commit da42bcb
Showing 1 changed file with 10 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -792,6 +792,7 @@ private static void loadPreferences(Properties context) {
pstmt.close();
}

// TODO: Improve with only table dimensions
// Default Values
log.info("Default Values ...");
sql = "SELECT t.TableName, c.ColumnName "
Expand All @@ -800,18 +801,19 @@ private static void loadPreferences(Properties context) {
+ "WHERE c.IsKey='Y' AND t.IsActive='Y'"
+ " AND EXISTS (SELECT * FROM AD_Column cc "
+ " WHERE ColumnName = 'IsDefault' AND t.AD_Table_ID=cc.AD_Table_ID AND cc.IsActive='Y')";
pstmt = DB.prepareStatement(sql, null);
rs = pstmt.executeQuery();
while (rs.next()) {
loadDefault (context, rs.getString(1), rs.getString(2));
}
rs.close();
pstmt.close();
pstmt = null;
// pstmt = DB.prepareStatement(sql, null);
// rs = pstmt.executeQuery();
// while (rs.next()) {
// loadDefault (context, rs.getString(1), rs.getString(2));
// }
// rs.close();
// pstmt.close();
} catch (SQLException e) {
log.log(Level.SEVERE, "loadPreferences", e);
e.printStackTrace();
} finally {
pstmt = null;
rs = null;
DB.close(rs, pstmt);
}
// Country
Expand Down

0 comments on commit da42bcb

Please sign in to comment.