[Hibernate-devel] what to do about select distinct.....
I think I need to break something :( Very early on in the project, when Hibernate queries just returned a single-column result sets containing entities, I made a decision to have Hibernate always return distinct result sets. It sort of made sense at the time but now that Hibernate queries can return all sorts of stuff, it no longer makes much sense This was not a very well-thought out decision, actually. What I would really like to do is push responsibility for this into the application by allowing the DISTINCT keyword in the Hiberante query and remove the select="distinct|all" mapping attribute. Unfortunately, this change would break existing code that assumes a distinct result set from a query without an explicit "DISTINCT". On the other hand, it would allow more flexibility for the user, be more predictable (clearer semantics) and simplify the implementation. No more hidden magic to trim a non-distinct SQL resultset to a distinct Hibernate result set. what does everyone think about this change? --- This sf.net email is sponsored by:ThinkGeek Welcome to geek heaven. http://thinkgeek.com/sf ___ Hibernate-devel mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/hibernate-devel
Re: [Hibernate-devel] what to do about select distinct.....
we r also using hibernate in a production environment. this change makes sense and is not a big deal for us, so go for it. brad - Original Message - From: "Jon Lipsky" <[EMAIL PROTECTED]> To: "Christian Bauer" <[EMAIL PROTECTED]>; Cc: <[EMAIL PROTECTED]> Sent: Wednesday, August 07, 2002 4:06 PM Subject: Re: [Hibernate-devel] what to do about select distinct. > Hi... > > I thought I would chime in since I am one of the few people who has a > project using Hibernate in a production environment. > > I took a look at my code and I don't think this change would break anything, > however you never know. :-) I'm sure other people could do what I do and > bundle a specific version of Hibernate with a specific version of their > application. In my case, I have bundled the 1.0 release of Hibernate with > the 1.0 release of my project since I know everything is working correctly > together. > > As to making the change. I support it. That was one thing I always > wondered why it wasn't in the query language. > > Jon... > > - Original Message - > From: > To: "Christian Bauer" <[EMAIL PROTECTED]> > Cc: <[EMAIL PROTECTED]> > Sent: Wednesday, August 07, 2002 3:42 AM > Subject: Re: [Hibernate-devel] what to do about select distinct. > > > > > > >Well, my concerns to this change are not technical. I appreciate the > > >decision and think it's better to break things now in an early stage. > > > > yeah, I do think that if something like this looks inevitable then 'tis > > best it be done quickly. > > > > But I *do* want to make it clear that I don't plan to make a habit of > > things like this. > > > > >But I think not a lot of people will be using Hibernate in a production > > >environment. > > > > No not *many* people, but there are a few and I'm sensitive to their > > concerns because they have been supporting the project from an early > > stage. Of course, some of those projects can probably continue to use > > whatever older version they are currenty using (or at least upgrade > > as far as 1.0.1b which is quite reliable. > > > > I will probably maintain 1.0.x as a seperate branch if any major bug shows > > up in 1.0.1. > > > > For projects in development, it probably isn't such a huge wrenching > > change to add "distinct" in a couple of query strings. (Most queries > > return distinct result sets with or without the distinct keyword > > *anyway*) > > > > P.S. Christian, I added the FAQ page to version 1.1 beta 2 but I had a > > question for you: are we continuing to use AFT for the website? Or should > I > > be doing new stuff like this in docbook? > > > > > > > > --- > > This sf.net email is sponsored by:ThinkGeek > > Welcome to geek heaven. > > http://thinkgeek.com/sf > > ___ > > Hibernate-devel mailing list > > [EMAIL PROTECTED] > > https://lists.sourceforge.net/lists/listinfo/hibernate-devel > > > > > > --- > This sf.net email is sponsored by:ThinkGeek > Welcome to geek heaven. > http://thinkgeek.com/sf > ___ > Hibernate-devel mailing list > [EMAIL PROTECTED] > https://lists.sourceforge.net/lists/listinfo/hibernate-devel > --- This sf.net email is sponsored by:ThinkGeek Welcome to geek heaven. http://thinkgeek.com/sf ___ Hibernate-devel mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/hibernate-devel
Re: [Hibernate-devel] what to do about select distinct.....
On 07 Aug (11:11), Gavin_King/[EMAIL PROTECTED] wrote: > What I would really like to do is push responsibility for this into the > application by allowing the DISTINCT keyword in the Hiberante query and > remove the select="distinct|all" mapping attribute. > > Unfortunately, this change would break existing code that assumes a > distinct result set from a query without an explicit "DISTINCT". Well, my concerns to this change are not technical. I appreciate the decision and think it's better to break things now in an early stage. But I think not a lot of people will be using Hibernate in a production environment. I have a small test application (an AddressBook) that I use to stress and feature test O/R mappers and all kind of things. It's really basic, the most complex thing is bidirectional one-to-many relationships (no M:N). Hibernate managed this application at 1.0.1, which was only two or three weeks ago. I know from my experience that it will take a lot more to make a useful application. I doubt anyone is currently using Hibernate for that purpose (no offence meant, I really believe it will be in the near future). -- Christian Bauer [EMAIL PROTECTED] --- This sf.net email is sponsored by:ThinkGeek Welcome to geek heaven. http://thinkgeek.com/sf ___ Hibernate-devel mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/hibernate-devel
Re: [Hibernate-devel] Logging and Serilization and Applets (oh my)
> Anyone have any ideas why this is happening and/or how to fix it? Its possibly a problem with the commons-logging stuff (i've seen some funny things happen before with serialization). Could you try commenting out all the references to commons logging in cirrus.hibernate.impl.LazyInitializer? If that helps, I will try for a similar fix in the next version. --- This sf.net email is sponsored by:ThinkGeek Welcome to geek heaven. http://thinkgeek.com/sf ___ Hibernate-devel mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/hibernate-devel
