|
View:
New views
3 Messages
—
Rating Filter:
Alert me
|
|
|
UserType and tiny blobHi,
I have a domain object defined as follow : class Question { String name String description LinkedHashMap<String,AbstractParameter> params = new LinkedHashMap<String,AbstractParameter>(20) static embedded = ['params'] static mapping = { params type: LinkedHashMapUserType } static constraints={ params(maxSize:1048567) } } To store the "params" attribute, I have my own hibernate UserType. By setting the maxSize constraint, I expect the blob size of the "params" column to be Medium, but it remains Tiny... So does the constraint mechanism drives the blob size in this case ? Regards, Olivier. |
|
|
Re: UserType and tiny blobIt depends, you may need to drop and recreate the table, if the column
already exists it may not update the table to avoid loss of data Cheers On Fri, May 16, 2008 at 10:51 AM, olivier FRESSE <olivier.fresse@...> wrote: > Hi, > I have a domain object defined as follow : > > class Question { > > String name > String description > LinkedHashMap<String,AbstractParameter> params = new > LinkedHashMap<String,AbstractParameter>(20) > > > > > static embedded = ['params'] > > static mapping = { params type: LinkedHashMapUserType } > > static constraints={ > params(maxSize:1048567) > } > > > } > > To store the "params" attribute, I have my own hibernate UserType. > > By setting the maxSize constraint, I expect the blob size of the "params" > column to be Medium, but it remains Tiny... > > So does the constraint mechanism drives the blob size in this case ? > > Regards, > > Olivier. > > > -- Graeme Rocher Grails Project Lead G2One, Inc. Chief Technology Officer http://www.g2one.com --------------------------------------------------------------------- To unsubscribe from this list, please visit: http://xircles.codehaus.org/manage_email |
|
|
Re: UserType and tiny blobWell I've tried to drop the table, but the column is always recreated as a tinyblob.
Maybe there is way to force the mapping to a mediumblob in Hibernate's configuration. I'm still searching :-) O. 2008/5/17 Graeme Rocher <graeme@...>: It depends, you may need to drop and recreate the table, if the column |
| Free Forum Powered by Nabble | Forum Help |