-->
These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 3 posts ] 
Author Message
 Post subject: comment mapper O/N avec type hibernate yes_no ?
PostPosted: Tue Jun 14, 2005 4:12 am 
Newbie

Joined: Wed Jun 08, 2005 5:15 am
Posts: 5
Need help with Hibernate? Read this first:
http://www.hibernate.org/ForumMailingli ... AskForHelp

Hibernate version: 3

bonjour,
j'ai dans ma base des colonnes de type char(1) contenant O ou N
je voulais les mapper avec un type hibernate yes_no ou true_false
mais ils semblent limiter à Y/N ou T/F
comment faire ?


Top
 Profile  
 
 Post subject:
PostPosted: Tue Jun 14, 2005 6:35 am 
Regular
Regular

Joined: Tue May 03, 2005 8:19 am
Posts: 53
Location: Paris
essaye la property à
hibernate.query.substitutions true 1, false 0, yes 'O', no 'N'


Top
 Profile  
 
 Post subject:
PostPosted: Thu Jun 16, 2005 8:49 pm 
Hibernate Team
Hibernate Team

Joined: Sun Sep 14, 2003 3:54 am
Posts: 7256
Location: Paris, France
tu peux aussi écrire ton propre type utilisateur (en implémentant UserType). C'est plus propre parce que la conversion est faites partout (chargement sauvegarde etc, pas suelement pdt une requete).

_________________
Emmanuel


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 3 posts ] 

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.