Andreas Joseph Krogh wrote:
> I get around this problem in Hibernate by using this combination:
>
> @Column(name="my_name")
> @Lob
> @Type(type="org.hibernate.type.StringClobType")
>
> ...but the StringClobType is deprecated.
>
It really makes it so much easier to have a TEXT column mapped to a 'String'.
@Entity public class Foo
{
@Id
private String ident;
private String somethingBackedByTEXT;
...
}
FWIW, in a database like Oracle that does have CLOBs it's still a lot easier
with Hibernate to map CLOBs to 'String' than to 'Clob', as I learned from
experience. Even the Hibernate documentation recommends against mapping to
'Clob'.
--
Lew
Ceci n'est pas une fenêtre.
.___________.
|###] | [###|
|##/ | *\##|
|#/ * | \#|
|#----|----#|
|| | * ||
|o * | o|
|_____|_____|
|===========|