The normal code is to return 0, because the meaning of this value is the number of affected rows. Since the original value here is already 2, the result of the number of affected rows is 0, which is correct. I don’t know much about this framework. I guess the reason is as follows: Because the framework considers that the result here is generally used as a sign to judge whether the operation is successful or not. If it keeps returning 0, it will enter the wrong logic, so most frameworks will be re-modified. this value.
The normal code is to return
0
, because the meaning of this value is the number of affected rows. Since the original value here is already 2, the result of the number of affected rows is 0, which is correct.I don’t know much about this framework. I guess the reason is as follows:
Because the framework considers that the result here is generally used as a sign to judge whether the operation is successful or not. If it keeps returning 0, it will enter the wrong logic, so most frameworks will be re-modified. this value.