title: Trying to build easy application with database
body: <p>I am trying to build an application just for save records and delete them for now, I new with Java and database, when I save it works fine but when I try to remove I got an error: </p>
  
  <pre><code>Comparisons between 'LONG VARCHAR (UCS_BASIC)' and 
      'LONG VARCHAR (UCS_BASIC)' are not supported.
  </code></pre>
  
  <hr>
  
  <pre><code>private void SaveBtnActionPerformed(java.awt.event.ActionEvent evt) {
      try{
          conn = DriverManager.getConnection("jdbc:derby://localhost:1527/Test", "app", "testcode");
          st = (Statement) conn.createStatement();
          String sql = "INSERT INTO APP.UNTI(ID,NAME) VALUES(?,?)";
          PreparedStatement ps = conn.prepareStatement(sql);
          ps.setString(1, J1.getText().trim());
          ps.setString(2, J2.getText().trim());
          if(ps.executeUpdate()&gt;0){
              JOptionPane.showMessageDialog(null, "insert succusful");
          }
      }catch(SQLException xmp){
         System.out.println("error");
      }
  }                                       
  
  private void RemoveBtnActionPerformed(java.awt.event.ActionEvent evt) {                                          
      // TODO add your handling code here:
        try{
          conn = DriverManager.getConnection("jdbc:derby://localhost:1527/Test", "app", "testcode");
          st = (Statement) conn.createStatement();            
          PreparedStatement ps = conn.prepareStatement("DELETE FROM UNTI WHERE NAME = ? ");
          System.out.println("ok");
          ps.setString(1,J2.getText().trim());           
          if(ps.executeUpdate() &gt; 0){
              JOptionPane.showMessageDialog(null, "insert succusful");
          }
      }catch(SQLException xmp){
         System.out.println(xmp.getMessage()  );
      }catch(NullPointerException xmp){
          System.out.println(xmp.getMessage()  );
      }
  
  }     
  </code></pre>