Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

MyBatis 3.5.0 inconsistent handling of keyProperty #1485

morvael opened this Issue Feb 25, 2019 · 3 comments


None yet
3 participants
Copy link

morvael commented Feb 25, 2019

@Options(useGeneratedKeys = true, keyProperty = "", keyColumn = "id")
int insertDataObject(@Param("n") DataObject dataObject);

In 3.5.0 keyProperty
"id" works with non-batch executor, "" doesn't
"" works with batch executor, "id" doesn't
"" works with multiple parameters in mapper method, "id" doesn't

Please allow using "" for single parameter methods with non-batch executors again. It was working before 3.5.0.


This comment has been minimized.

Copy link

kazuki43zoo commented Feb 25, 2019

Thank you for your reporting. Probably, this issue related with #1249. (This is specification changes since 3.5).

Could you support this?


This comment has been minimized.

Copy link

harawata commented Feb 26, 2019

I'll try to improve the consistency.
Thank you for the report!

@harawata harawata closed this in 36d3a4a Feb 27, 2019

@harawata harawata self-assigned this Feb 27, 2019

@harawata harawata added the bug label Feb 27, 2019

@harawata harawata added this to the 3.5.1 milestone Feb 27, 2019


This comment has been minimized.

Copy link

harawata commented Feb 27, 2019

@morvael ,

It should be fixed in the latest 3.5.1-SNAPSHOT.
As it was a major rewrite, I would suggest you to verify the fix with your solution. :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.