7 Replies Latest reply on Mar 31, 2010 8:21 AM by TSGal

    Found a JDBC bug. Can't update a row when any number field has a fractional amount

    warrenn

      Summary

      Found a JDBC bug. Can't update a row when any number field has a fractional amount

      Description of the issue

      FileMaker version 10.0v6 6-18-2009 I'm having an issue when accessing my database with JDBC.  I am able to update most records just fine.  But certain records I can't update.  I get the message: updateRow() Failed: Message: [DataDirect][SequeLink JDBC Driver]Row update failed. Vendor: 6057 State:  HY000  I slowly cleared the fields in the record until the update would work.  The thing that was causing a problem was a number field that was not a whole number (i.e. 100.5 instead of 100).  If I set the field to a whole number everything worked.  However, my query had nothing at all to do with that number field.  I was updating fields F1, F2 and the number field was F27. You can easily recreate this.  Create a database with the following fields: CustId   TextPayment NumberComment Text Create these customers: CustId 1Payment 100Comment Whole number payment CustId 2Payment 100.1Comment Fractional payment Start up the testforjdbc test program that comes with FileMaker.  Connect to the database and create a JDBC 2.0 statement:    stmt = con.createStatement(ResultSet.TYPE_FORWARD_ONLY, ResultSet.CONCUR_UPDATABLE);Do a query to select the CustId and Comment fields for the record which has the fractional payment. Notice that I'm not including the Payment field in my query:  Select CustId,Comment from JdbcNumberBug where CustId = '2'In the results set update the Comment cell and then update the row.  You'll get this error:updateRow() Failed: Message: [DataDirect][SequeLink JDBC Driver]Row update failed. Vendor: 6057 State:  HY000 But if you do the same thing for CustId=1, everything works fine.  If you change the Payment field for CustId=2 to be a whole number, everything works fine.  It's just when the number field has a fraction that the update fails.