In Hibernate this is handled by choosing the appropriate Dialect for your database. I have not used JPA, but I would guess it still has something to do with the configuration of your JPA implementation.
Nathan ----- Original Message ----- From: "Bajju" <[EMAIL PROTECTED]> To: [email protected] Sent: Tuesday, May 1, 2007 2:56:58 AM (GMT-0800) America/Los_Angeles Subject: [appfuse-user] map boolean field in model to char or integer In the example User model, there are four fields which are boolean, namely enabled accountExpired accountLocked credentialsExpired there are associated @Column annotations on these for JPA. For MySQL these fields are getting mapped to bit fields, on other databases such as db/2 there are no corresponding bit fields. How/What do I need to do, to specify that these fields are although boolean in model class but should be (say) char or integer (1,0) in the database from persistence prespective. Presently the annotation @Column is attached to the isExpired(), isLLocked() etc accessor methods. Rgds, Deepak BAJAJ -- View this message in context: http://www.nabble.com/map-boolean-field-in-model-to-char-or-integer-tf3674241s2369.html#a10266848 Sent from the AppFuse - User mailing list archive at Nabble.com. --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
