Fixed
Details
Assignee
Strong LiuStrong LiuReporter
Ray FanRay FanComponents
Fix versions
Affects versions
Priority
Major
Details
Details
Assignee
Strong Liu
Strong LiuReporter
Ray Fan
Ray FanComponents
Fix versions
Affects versions
Priority
Created August 17, 2010 at 1:17 PM
Updated March 21, 2011 at 7:09 PM
Resolved September 1, 2010 at 8:58 PM
SQL-92 standard indicates that right-padded spaces are part of the char, for example in the definition of the CAST function on p. 148. When source (SV=source value) and target (TV=target value, LTD=length of target datatype), then:
in most dialect, jdbc char type is mapped to char(1) or the default one which means char(255), so, in these cases, UUIDCharType will not work due the the space padded character value causing an exception in UUID.fromstring() called from UUID_parse on the returned value.
org.hibernate.test.id.uuid.sqlrep.sqlchar.UUIDCharTest can be used to reproduce this issue on other DBs except H2 and MySQL, it is a MySQL Gotchas