log4j.logger.org.hibernate.type = trace, console
可以看到?的內容
Hibernate: insert into USERS (VERSION, USERNAME, PASSWORD, DESCRIPTION, ENABLED, N_ID, USER_ID) values (?, ?, ?, ?, ?, ?, ?)
xxx>2009-08-17 10:32:50,949 DEBUG[TimestampType:133]binding '2009-08-17 10:32:50' to parameter: 1
xxx
>2009-08-17 10:32:50,949 DEBUG[StringType:133]binding 'asdf' to parameter: 2
xxx
>2009-08-17 10:32:50,949 DEBUG[StringType:133]binding 'asdf' to parameter: 3
xxx
>2009-08-17 10:32:50,949 DEBUG[StringType:133]binding 'asdf' to parameter: 4
xxx
>2009-08-17 10:32:50,949 DEBUG[BooleanType:133]binding 'true' to parameter: 5
>2009-08-17 10:32:50,949 DEBUG[StringType:133]binding '40288be52031e8d4012031f78d07000e' to parameter: 6
xxx
>2009-08-17 10:32:50,949 DEBUG[StringType:133]binding '40288b6c232632be012326332be60001' to parameter: 7
在oracle中使用Number(5,2)的data type:
mapping須設
< property name="multiple" not-null="true" type="integer" >
< column name="MULTIPLE" sql-type="number(5,2)" >< /column >
< /property >
沒有留言:
張貼留言