private void jTextFieldFindKeyTyped(java.awt.event.KeyEvent evt) {//GEN-FIRST:event_jTextFieldFindKeyTyped
        // TODO add your handling code here:
        try {
            clearVentHas();
            clearVentas();
            String sql = "SELECT t1.idVentas AS id_venta, t2.nombre AS empleado, t1.precio_total "
                    + "FROM ventas AS t1, empleados AS t2 "
                    + "WHERE t1.empleados_idempleados = t2.idempleados "
                    + "AND t2.nombre LIKE ? "
                    + "ORDER BY t1.idventas";
            Connection conn = Conexion.GetConnection();
            PreparedStatement ps = conn.prepareStatement(sql);
            ps.setString(1, "%"+jTextFieldFind.getText()+"%");
            
            ventas = ps.executeQuery();

            while (ventas.next()) {
                String[] rows = {ventas.getString(1), ventas.getString(2), ventas.getString(3)};
                tmVenta.addRow(rows);
            }
            jTableVentas.setModel(tmVenta);
        } catch (SQLException e) {
            System.out.println(e.getMessage());
        }
    }//GEN-LAST:event_jTextFieldFindKeyTyped