[hibernate-issues] [Hibernate-JIRA] Created: (HHH-7293) Change index name to meet Oracle 30 chars limit

Samuel Fung (JIRA) noreply at atlassian.com
Wed May 2 06:25:48 EDT 2012


Change index name to meet Oracle 30 chars limit
-----------------------------------------------

                 Key: HHH-7293
                 URL: https://hibernate.onjira.com/browse/HHH-7293
             Project: Hibernate ORM
          Issue Type: Patch
          Components: core
    Affects Versions: 4.1.1
         Environment: Oracle 11g
            Reporter: Samuel Fung
            Priority: Minor
         Attachments: diff.txt

I have an entity class that use table-per-class inheritance. One property in the base class is annotated with @org.hibernate.annotations.Index(name="..."). When Hibernate creates DB schema, the index name is prepended with the concrete class name. The final name exceeds Oracle limit of names <30 chars.

I changed org.hibernate.mapping.DenormalizedTable, the index name is the hex string of hashcode of the original name. This comply the Oracle limit while (very likely) maintains uniqueness of the name.

Sorry that the submitted patch is not exactly a svn diff (made by diff -u).

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

        


More information about the hibernate-issues mailing list