-
Notifications
You must be signed in to change notification settings - Fork 74
Add database columns with CURRENT_TIMESTAMP support #30
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
base: master
Are you sure you want to change the base?
Changes from all commits
245cc6a
301500b
0a02dc1
64fdc16
5843654
9314a77
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -18,8 +18,7 @@ public static String toJavaType(int typeCode) { | |
return "Long"; | ||
// case Types.BINARY: | ||
case Types.BIT: | ||
// return "Boolean"; | ||
return "boolean"; | ||
return "Boolean"; | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This can be a breaking change. If I remember correctly, setting primitive type here means the value will be There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. When the database has a nullable column, primitive type field of the entity can't store null, NPE will occur. Wrapped Type can represent true/false and not set There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Assuming we force make all boolean fields to be Sometimes, we use ExampleMatcher of JPA, and telling JPA to ignore the null value field:
or mybatis :
If the field type is primitive, we will always query data with There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @slankka That makes sense. That said, I'd like to avoid bringing any breaking changes to this library. This library is widely used at SmartNews and I am no longer working for the company. If you're still interested in working this PR and have time for it, could you introduce a flag in the configuration allowing users to choose |
||
case Types.BLOB: | ||
return "Blob"; | ||
case Types.BOOLEAN: | ||
|
Uh oh!
There was an error while loading. Please reload this page.