[hibernate-issues] [Hibernate-JIRA] Commented: (HHH-1501) insert long string (more than 32700) fails on derby

Sergey Vladimirov (JIRA) noreply at atlassian.com
Wed May 5 18:24:07 EDT 2010


    [ http://opensource.atlassian.com/projects/hibernate/browse/HHH-1501?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=36927#action_36927 ] 

Sergey Vladimirov commented on HHH-1501:
----------------------------------------

Steve,

I'm sorry that it looks like i require some inadequate behavior from Hibernate and/or it's developers. It's purely your rule what shall it do and how should it work.

The reason of filling this bug is that i feel that Derby dialect has not just a wrong behaviour, but it is incompatible with other dialects because of this bug. Let me explain.

I'm considering Hibernate as the most powerfull JPA implementation at this moment. As part of it I considering it as something, that abstracts my application from database vendor-specific details. In a such way, that I can throw out MySQL InnoDB (that is currently used) and use Derby (that is used for testing now) or Oracle or MySQL MyISAM or MS SQL. And, according to my understanding of Hibernate place in application stack, such change shall only require single change in application configuration - just replace the dialect.

But the issue, described in this bug, introduces incompatibility between, for example, MySQL and Derby. If I declare some property as LOB String, it can contain up to 2 Gb of data, if MySQL dialect is used. But with Derby dialect it can contain only 32 Kb of data. Thus, we have and incompatibility between dialect, and, i believe, Derby dialect shall be fixed. Or, at least, it shall be described clearly by HIbernate, that 32 Kb is the minimum guarantly of Lob length.

Filling this bug was a gesture, not a requirement. We already created our version of MySQL, MS SQL and Derby dialects to enforce some additional compatibility. But I believe that those fixes and such interdialect compatibility shall be part of Hibernate without additional code by user in future versions of Hibernate.

If you insist that such changes shall not be made in Hibernate - it's okay. But personally i believe that such a requirement will arise again as soon as someone will need to work with different databases from same application.

Thanks for your work and best regards,
Sergey Vladimirov

> insert long string (more than 32700) fails on derby
> ---------------------------------------------------
>
>                 Key: HHH-1501
>                 URL: http://opensource.atlassian.com/projects/hibernate/browse/HHH-1501
>             Project: Hibernate Core
>          Issue Type: Bug
>          Components: core
>    Affects Versions: 3.5.0-Beta-2
>         Environment: Derby 10
>            Reporter: Sergey Vladimirov
>            Priority: Trivial
>
> http://issues.apache.org/jira/browse/DERBY-102
> VARCHAR maximum length 32 672
> LONG VARCHAR maximum length 32 700
> CLOB maximum length 2 147 483 647
> BLOB maximum length 2 147 483 647
> this issue can be reproduced by org.hibernate.test.lob.TextTest (in 3.5 beta1,2) with change org.hibernate.test.lob.LongStringTest.LONG_STRING_SIZE > 32700

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://opensource.atlassian.com/projects/hibernate/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        


More information about the hibernate-issues mailing list