public void getListDetails(String i) {
        String query = "select invdt,billingdt,invamt,remarks,reference from goods_sold_hdr where invid="+i;
        Statement stmt = null;       
        this.connect();
        conn = this.getConnection();
        try {
            stmt = conn.createStatement();
        }
                
        catch (SQLException e)  {
            e.printStackTrace();
        }
		
        ResultSet rs;
        try {
            rs = stmt.executeQuery(query);
            if(rs.next()) {
                textRemarks.setText(rs.getString("remarks"));
                textInvDate.setText(df.format(df.parse(rs.getString("invdt"))));
                textBilDate.setText(df.format(df.parse(rs.getString("billingdt"))));
                textAmount.setText(String.format("%.2f", Float.parseFloat(rs.getString("invamt"))));
                textReference.setText(rs.getString("reference"));
            }
            rs = null;
        }
        catch(Exception e) { }
        //PURCHASE DETAILS
        query = "select membername, balance, description from goods_sold_dtl where invid="+i;
        
        try {
            rs = stmt.executeQuery(query);
                try {                    
                    tableUtils.updateTableModelData((DefaultTableModel) listDetails.getModel(), rs, 3);
                }
                catch (Exception ex) {
                    Logger.getLogger(ViewMember.class.getName()).log(Level.SEVERE, null, ex);
                }
        }
        catch(Exception e) { }
        finally {
            this.disconnect();
        }
    }