You are viewing a plain text version of this content. The canonical link for it is here.
Posted to torque-user@db.apache.org by Marc Lustig <ma...@marclustig.com> on 2003/02/18 17:46:05 UTC

how to map blob <--> java.lang.String (was: AW: how to map textarea -> intake field __ -> column-type blob)

[sorry, I just posted this with a wrong subject]

Problem is well known: Torque maps type="BLOB" to byte[]

What would be the easiest way to cause Torque to map it against String
instead of byte[] ?

Otherwise the only solution would be to create additional get/setter with
different names and map from String <-> byte[].


> -----Ursprüngliche Nachricht-----
> Von: Marc Lustig [mailto:mail@marclustig.com]
> Gesendet: Dienstag, 18. Februar 2003 17:16
> An: Turbine Users List
> Betreff: how to map textarea -> intake field __ -> column-type blob
>
>
>
> The content supplied by a textarea-field might be larger than 255
> characters. Therefore I used column type "blob" for the corresponding
> table-field. (MySQL)
>
> Now I want Intake to map this using group.setProperties(bo).
> In the group-field I specified type="String".
>
> This results in:
>
> java.lang.Thread.run(Thread.java:536) Caused by:
> org.apache.turbine.util.TurbineException: An exception prevented
> the setting
> property Fussa of de.geoconnect.audiotex.om.AbrechnungLayout@1f to c:
> argument type mismatch at
> org.apache.turbine.services.intake.model.Field.setProperty(Field.java:633)
> at
> org.apache.turbine.services.intake.model.Group.setProperties(Group
.java:382)
> at
>
>
> I wonder what else intake-field-type to use for a proper mapping.
>
> Anybody having solved a scenario like this?
> It's not really unusual.
>
> Marc
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: turbine-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: turbine-user-help@jakarta.apache.org
>