private void processLoadQueryToTable(JTable tabel, ResultSet resultSet, HashMap idMap, boolean createColumn) {
        ResultSetMetaData metaData;
        int indexOfRow = 0; // index dimulai dari nol.
        int nColoumn;
        int nRow;
        String[][] result;
        int lastRow;
        LoggingWindow.getInstance().addToLog("***" + "[loadQueryToTable]: displaying resultSet" + resultSet);
        try {
            lastRow = tabel.getSelectedRow();

            metaData = resultSet.getMetaData();// penting digunakan, tentang kolom
            nColoumn = metaData.getColumnCount();
            DefaultTableModel model;
            if (createColumn) {
                model = new DefaultTableModel(); // --- spesifik JTabel
                for (int i = 2; i <= nColoumn; i++) // --- spesifik JTabel, td mulai dari 1, dipakai u/ ID, yg tdk tampil di Table
                { // --- spesifik JTabel
                    model.addColumn(metaData.getColumnName(i)); // --- spesifik JTabel
                } // --- spesifik JTabel
            } else {
                model = (DefaultTableModel) tabel.getModel();
                model.setRowCount(0);
            }

            resultSet.last();// menuju paling baris terakhir
            nRow = resultSet.getRow();
            result = new String[nRow][];
            resultSet.beforeFirst();// kembali ke sblm brs pertma;
            if (idMap != null) {
                idMap.clear();
            }

            while (resultSet.next()) {// disini skalian langsung ke baris berikutnya.                
                result[indexOfRow] = new String[nColoumn];
                if (idMap != null) {
                    idMap.put(indexOfRow, resultSet.getString(1));
                }
                for (int i = 1; i < nColoumn; i++) { //td i=0
                    result[indexOfRow][i - 1] = resultSet.getString(i + 1);
                }
                model.addRow(result[indexOfRow]); // --- spesifik JTabel
                indexOfRow++;

            }
            tabel.setModel(model); // --- spesifik JTabel
            tabel.getSelectionModel().setSelectionMode(ListSelectionModel.SINGLE_SELECTION);
            if (lastRow > indexOfRow) {
                tabel.getSelectionModel().setSelectionInterval(nRow, nRow);
            } else {
                tabel.getSelectionModel().setSelectionInterval(0, 0);
            }

            //connectiondb.close();
        } catch (Exception ex) {
            result = null;
            Startup.getInstance().debug("Main.loadQueryToTable, resultset: " + resultSet, ex.getMessage());
        }
    }