From: Brad C. <bra...@wo...> - 2002-11-29 23:46:37
|
=20 > Without support for CLOBs is there any way use Hibernate > to persist fields longer than 255 characters? What type > should I use in my mapping file? here r two possiblities: 1. i have a vague recollection of doing this by having a String property = in my java class, letting hibernate generate the schema and then = manually changing the column type in the database (sapdb in this case) = from varchar to the appropriate clob type. this wasn't much of hassle = as i did the schema creation via ant - first called hibernate's schema = export tool and then ran a sql script to fix the column type. 2. use a blob (as far as hibernate is concerned). make a bogus getter = and setter that uses a byte[] that reads and writes too your String = field and tell hibernate about this and not your real getter and setter. brad |