[hibernate-issues] [Hibernate-JIRA] Commented: (HHH-3422) Oracle error: ORA-01754: a table may contain only one column of type LONG

Martin Vařecha (JIRA) noreply at atlassian.com
Wed Dec 3 11:06:17 EST 2008


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

Martin Vařecha commented on HHH-3422:
-------------------------------------

There is solution, but it's not obvious.
I added annotation javax.persistence.Lob ...

    @Lob
    @Column(name="text_content", length=32000)
    private String textContent;

    @Lob
    @Column(name="html_content", length=32000)
    private String htmlContent;

It creates columns with CLOB type. 
Although column size is 4000, it's possible to insert 32000 characters long String.

> Oracle error: ORA-01754: a table may contain only one column of type LONG
> -------------------------------------------------------------------------
>
>                 Key: HHH-3422
>                 URL: http://opensource.atlassian.com/projects/hibernate/browse/HHH-3422
>             Project: Hibernate Core
>          Issue Type: Bug
>    Affects Versions: 3.2.6
>         Environment: Oracle 10g express edition release 10.2.0; Hibernate 3.2.6 GA; org.hibernate.dialect.Oracle10gDialect
>            Reporter: Martin Vařecha
>            Assignee: Diego Plentz
>
> I get this error "ORA-01754: a table may contain only one column of type LONG" during creating tables, because I have JPA bean with these two fields:
>     @Column(name="text_content", length=16000)
>     private String textContent;
>     @Column(name="html_content", length=32000)
>     private String htmlContent;
> For these huge text types column of long type is used and oracle doesn't allow more then one long in the table.

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