fixed mysql update error

MySQL return 0 affected row when the new data is the same as the old
data, so