注释接口 Column
Optional annotation to specify the column name for scalar properties.
If the column name inferred according to the Java/Kotlin property name based on Rule `word1Word2...WordN -> WORD1_WORD2_..._WORDN` is different from the column name in the database, this annotation must be used.
Note: This annotation can not be used to map foreign key.
For foreign key, JoinColumn is useful
-
可选元素概要
可选元素
-
元素详细资料
-
name
String name- 默认值:
""
-
sqlType
String sqlTypeFor non-array columnIf these two conditions are matched- The `any(?)` is supported by database, that is, `Dialect.isAnyOfArraySupported()` returns true
- The `sqlType` of this annotation is specified, or the current property returns `long` or `Long`
where(table.id().in(Arrays.asList(1L, 2L, 3L, 4L)))
generate the SQLwhere tb_1_.ID = any(?)
- If the property type is `long` or `Long`, it will be considered as `bigint`
- Otherwise, please specify it manually
- 默认值:
""
-
sqlElementType
String sqlElementTypeFor array column- 默认值:
""
-