title: why is my database not updating? (using netbeans xampp mysql)
body: <p>when i run the file, it accepts the query and says update success but when i check my database why does it not update?</p>
  
  <pre><code> private void btnUpdateDeleteActionPerformed(java.awt.event.ActionEvent evt) {                                                
          // TODO add your handling code here:
          if(radioUpdate.isSelected()){
  
              try{
            Class.forName("com.mysql.jdbc.Driver");
              cn=DriverManager.getConnection("jdbc:mysql://localhost:3306/soften?zeroDateTimeBehavior=convertToNull","root","");
              st=cn.createStatement();
              String sql="UPDATE `tblproductssales` SET "
                      +" product = ?,quantity = ?"
                      +" WHERE 'sale no' = ?";
  
              PreparedStatement pst = cn.prepareStatement(sql);
              pst.setString(1,editProduct.getText());
              pst.setString(2,editQty.getText());
             pst.setString(3,editSaleID.getText());
  
              pst.executeUpdate();
              JOptionPane.showMessageDialog(null,"success update");
              //**when i run the file this JOPtionpPane shows
        }catch(Exception e){e.printStackTrace();}   
  
          }
      }   
  </code></pre>
  
  <p><a href="https://i.stack.imgur.com/vs8yM.png" rel="nofollow noreferrer">here is my database, the table name is tblproductssales</a></p>