Re: [Hibernate] Composite Id one-to-one relationship
Please remove constraint=true from parent table. - Original Message - From: "Neema, Devesh (MED, Contractor)" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Tuesday, December 02, 2003 9:39 AM Subject: [Hibernate] Composite Id one-to-one relationship Hi Hibernate Users, I have a tables with following Structure : Table A :- Composite ID 1. PatId:- many-to-one relationship with Table C 2.ParticipantId :- many-to-one relationship with Table D Table B :- Composite ID 1.PatId 2.ParticipantId Table A and Table B are one-to-one I have represented this in HBM file Is this correct way to represent the relationship ? Devesh --- This SF.net email is sponsored by: SF.net Giveback Program. Does SourceForge.net help you be more productive? Does it help you create better code? SHARE THE LOVE, and help us help YOU! Click Here: http://sourceforge.net/donate/ ___ hibernate-devel mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/hibernate-devel --- This SF.net email is sponsored by: SF.net Giveback Program. Does SourceForge.net help you be more productive? Does it help you create better code? SHARE THE LOVE, and help us help YOU! Click Here: http://sourceforge.net/donate/ ___ hibernate-devel mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/hibernate-devel
Re: [Hibernate] Help, I implemented Criteria.count() and no one cares!!
Really, I know its frustrating, but I feel instinctively that its a mistake to try to half-solve this particular problem before we are ready to really sit down and think about the it properly. Its like Example queries: people asked for this feature many times and if we would have given it to them then, our QBE API would be much, much less elegant than what it is now. If you can propose a really elegant way to do projection/aggregation in the Criteria API, I'll consider it. Chris Nelson wrote: Gavin, Thanks for getting back to me. I read an earlier post where you had said something like this, but I was hoping you might reconsider. I agree that having something even more generic would be better, but having a count method now is absolutely critical to anyone wanting to use the Criteria API and needing to do paging. I also feel that the other methods like avg(), max(), etc, are not nearly as important as count() for most people. I certainly understand the slippery slope idea, but I'm not sure it has to apply here. I would be willing to commit to refactoring, removing, or doing whatever is needed to adapt this method to fit in with the aggregation functionality when it comes along. I'd much rather do that than have to redo this patch for each release of Hibernate in the meanwhile. I also think there are people who may need this method who may be uncomfortable with using a patched version of Hibernate. Incidentally, I'd be happy to be involved in developing the aggregation functionality if I can be helpful. It seems like making the Select statement objectb available to sublasses might be a first step in that direction anyways. Of course, there seems to be some talk about having Criteria generate HQL and SQL with the new AST stuff (an idea which I rather like if it's feasible), so maybe not. Thanks again, Chris Nelson --- Gavin King <[EMAIL PROTECTED]> wrote: Hi, I apologise. Me not answering emails generally means I don't quite know what to say and am still thinking something through. Anyway, as I've indicated elsewhere, I don't want this stuff in the Criteria API *yet*. We havn't decided how we should implement projection/aggregation yet, and when we do, it won't be by adding 1000 methods like count(), avg(), max(), etc to the Criteria interface. Anyone who really needs this _now_ can use your patch, I suppose. peace Gavin Chris Nelson wrote: Guys, This is the 3rd time I have sent an email regarding this, and I'm starting to wonder if I have virtual bad breath or something ;) I'm hoping maybe people thought I was asking where is this method so I tried to make my subject a little more explicit this time. I submitted a patch (2 of em actually) to add the count() method to Criteria after seeing several posts about not having it and needing it myself. Is there a chance someone can look at it and tell me if it's ok? It's HB-474, and the second attachment is the corrected one (the first had an issue when used with limit queries). Thanks in advance, Chris Nelson __ Do you Yahoo!? Free Pop-Up Blocker - Get it now http://companion.yahoo.com/ --- This SF.net email is sponsored by: SF.net Giveback Program. Does SourceForge.net help you be more productive? Does it help you create better code? SHARE THE LOVE, and help us help YOU! Click Here: http://sourceforge.net/donate/ ___ hibernate-devel mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/hibernate-devel -- Gavin King JBoss Group +61 410534454 http://hibernate.org __ Do you Yahoo!? Free Pop-Up Blocker - Get it now http://companion.yahoo.com/ -- Gavin King JBoss Group +61 410534454 http://hibernate.org --- This SF.net email is sponsored by: SF.net Giveback Program. Does SourceForge.net help you be more productive? Does it help you create better code? SHARE THE LOVE, and help us help YOU! Click Here: http://sourceforge.net/donate/ ___ hibernate-devel mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/hibernate-devel
[Hibernate] velocity based renderer in cvs
http://forum.hibernate.org/viewtopic.php?t=926019&start=0&postdays=0&postorder=asc&highlight= /max --- This SF.net email is sponsored by OSDN's Audience Survey. Help shape OSDN's sites and tell us what you think. Take this five minute survey and you could win a $250 Gift Certificate. http://www.wrgsurveys.com/2003/osdntech03.php?site=8 ___ hibernate-devel mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/hibernate-devel
[Hibernate] Retrieving Object Problem
Hi, Registries.hbm.xml mapping file work fine will inserting and updating the record , but gives problem will retrieving Objects. Explanation : - It gives me trouble at two point while loading TCx1PtsiteT object . 1. while loading TA3PatientT object using TCx1PtsiteT object . Description :- In database Tables TA3PatientT and TCx1PtsiteT have one-to-one relationship on Composite Id TCx1PtsiteT have many-to-one relationship with TCx1ParticipantM & TCx1PatientT Here i get the following Exception SEVERE: IllegalArgumentException in class: com.ge.med.registries.acc_30.hibernate.TA3PatientT, getter method of property: participant 2. while loading TCx1AdmdisT object using TCx1PtsiteT object . Description :- Table = TCx1AdmdisT have many-to-one relationship with TCx1PtsiteT On column Participant_ID and PatID. Here i get the following Exception SEVERE: SQLException initializing collection java.sql.SQLException: [Microsoft][SQLServer 2000 Driver for JDBC]Invalid parameter binding(s). In hbm I have defined like this:- Help me out ... Devesh --- This SF.net email is sponsored by OSDN's Audience Survey. Help shape OSDN's sites and tell us what you think. Take this five minute survey and you could win a $250 Gift Certificate. http://www.wrgsurveys.com/2003/osdntech03.php?site=8 ___ hibernate-devel mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/hibernate-devel
Re: [Hibernate] Retrieving Object Problem
I'm probably not the person to give you good advice based on the mapping file alone, but my approach is to turn up hibernate debugging (in log4j config) and have a look at what is bound when and where the excetpion is caused. hth dim - Original Message - From: "Neema, Devesh (MED, Contractor)" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Wednesday, December 03, 2003 3:03 PM Subject: [Hibernate] Retrieving Object Problem Hi, Registries.hbm.xml mapping file work fine will inserting and updating the record , but gives problem will retrieving Objects. Explanation : - It gives me trouble at two point while loading TCx1PtsiteT object . 1. while loading TA3PatientT object using TCx1PtsiteT object . Description :- In database Tables TA3PatientT and TCx1PtsiteT have one-to-one relationship on Composite Id TCx1PtsiteT have many-to-one relationship with TCx1ParticipantM & TCx1PatientT Here i get the following Exception SEVERE: IllegalArgumentException in class: com.ge.med.registries.acc_30.hibernate.TA3PatientT, getter method of property: participant 2. while loading TCx1AdmdisT object using TCx1PtsiteT object . Description :- Table = TCx1AdmdisT have many-to-one relationship with TCx1PtsiteT On column Participant_ID and PatID. Here i get the following Exception SEVERE: SQLException initializing collection java.sql.SQLException: [Microsoft][SQLServer 2000 Driver for JDBC]Invalid parameter binding(s). In hbm I have defined like this:- Help me out ... Devesh --- This SF.net email is sponsored by OSDN's Audience Survey. Help shape OSDN's sites and tell us what you think. Take this five minute survey and you could win a $250 Gift Certificate. http://www.wrgsurveys.com/2003/osdntech03.php?site= ___ hibernate-devel mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/hibernate-devel --- This SF.net email is sponsored by OSDN's Audience Survey. Help shape OSDN's sites and tell us what you think. Take this five minute survey and you could win a $250 Gift Certificate. http://www.wrgsurveys.com/2003/osdntech03.php?site=8 ___ hibernate-devel mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/hibernate-devel
Re: [Hibernate] Retrieving Object Problem
Please stop posting the same questions to the dev list as you post to the user forum! This is not the right place for these kinds of questions anyway. TIA Neema, Devesh (MED, Contractor) wrote: Hi, Registries.hbm.xml mapping file work fine will inserting and updating the record , but gives problem will retrieving Objects. Explanation : - It gives me trouble at two point while loading TCx1PtsiteT object . 1. while loading TA3PatientT object using TCx1PtsiteT object . Description :- In database Tables TA3PatientT and TCx1PtsiteT have one-to-one relationship on Composite Id TCx1PtsiteT have many-to-one relationship with TCx1ParticipantM & TCx1PatientT Here i get the following Exception SEVERE: IllegalArgumentException in class: com.ge.med.registries.acc_30.hibernate.TA3PatientT, getter method of property: participant 2. while loading TCx1AdmdisT object using TCx1PtsiteT object . Description :- Table = TCx1AdmdisT have many-to-one relationship with TCx1PtsiteT On column Participant_ID and PatID. Here i get the following Exception SEVERE: SQLException initializing collection java.sql.SQLException: [Microsoft][SQLServer 2000 Driver for JDBC]Invalid parameter binding(s). In hbm I have defined like this:- Help me out ... Devesh --- This SF.net email is sponsored by OSDN's Audience Survey. Help shape OSDN's sites and tell us what you think. Take this five minute survey and you could win a $250 Gift Certificate. http://www.wrgsurveys.com/2003/osdntech03.php?site= ___ hibernate-devel mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/hibernate-devel -- Gavin King JBoss Group +61 410534454 http://hibernate.org --- This SF.net email is sponsored by OSDN's Audience Survey. Help shape OSDN's sites and tell us what you think. Take this five minute survey and you could win a $250 Gift Certificate. http://www.wrgsurveys.com/2003/osdntech03.php?site=8 ___ hibernate-devel mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/hibernate-devel