[hibernate-issues] [Hibernate-JIRA] Created: (METAGEN-61) Using SQLServerDialect, the DDL generated has wrong length(..) for strings! Defaults char(255)!

Colbert Philippe (JIRA) noreply at atlassian.com
Wed May 25 13:30:24 EDT 2011


Using SQLServerDialect, the DDL generated has wrong length(..) for strings!  Defaults char(255)!
------------------------------------------------------------------------------------------------

                 Key: METAGEN-61
                 URL: http://opensource.atlassian.com/projects/hibernate/browse/METAGEN-61
             Project: Hibernate Metamodel Generator
          Issue Type: Bug
          Components: processor
    Affects Versions: 1.1.1.Final
         Environment: Windows 7
            Reporter: Colbert Philippe
            Assignee: Hardy Ferentschik


I am using Microsoft SQL Azure as database, which is Microsoft SQL Server.   I use the dialect class org.hibernate.dialect.SQLServerDialect as indicated in the manual.

I have carefully specified the length (attribute length()) of my strings in each hbm.xml file of my project.   However, I noticed that the database uses a default 255 length for all strings in all classes of my project.   That's wrong!    

I tried creating a class with a string attribute by hand, that works.   The string has the proper length that I specified in my DDL.

Clearly there is an error in the generation of my DDL from class org.hibernate.dialect.SQLServerDialect..   It's a major error.


-- 
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