From: Jon L. <jon...@xe...> - 2002-09-24 13:07:56
|
Hi, I've implemented outer join support for Oracle 8. (Oracle 9 supports = the ANSI style outer joins.) I know Gavin is working on some refactoring right now, so I wanted to = make sure my work doesn't interfere with his before I check the patches = in. In order to implement this, I had to modify the following files = (along with what I did): Environment.java - Added a "useOracleJoins" environment parameter Loader.java - Added helper methods to generate the additions to the from = and the where clause for the Joins CollectionLoader.java - Added check for join type, and then generate = ANSI joins or Oracle joins. EntityLoader.java - Added check for join type, and then generate ANSI = joins or Oracle joins. OneToManyLoader.java - Added check for join type, and then generate ANSI = joins or Oracle joins. Gavin, if this sounds alright to you, and doesn't conflict with your = refactoring, then I will check this in. Thanks, Jon... |
From: Christoph S. <ch...@mc...> - 2002-09-24 13:22:23
|
Hey Jon! Oracle Outer Joins are great, I have been needing this for quite some = time :) But wouldnt it be better to let the database Dialect decide what kind of = outer joins is generated instead of introducing a new parameter? regards chris ----- Original Message -----=20 From: Jon Lipsky=20 To: hib...@li...=20 Sent: Tuesday, September 24, 2002 3:06 PM Subject: [Hibernate] Oracle Style Joins Implemented Hi, I've implemented outer join support for Oracle 8. (Oracle 9 supports = the ANSI style outer joins.) I know Gavin is working on some refactoring right now, so I wanted to = make sure my work doesn't interfere with his before I check the patches = in. In order to implement this, I had to modify the following files = (along with what I did): Environment.java - Added a "useOracleJoins" environment parameter Loader.java - Added helper methods to generate the additions to the = from and the where clause for the Joins CollectionLoader.java - Added check for join type, and then generate = ANSI joins or Oracle joins. EntityLoader.java - Added check for join type, and then generate ANSI = joins or Oracle joins. OneToManyLoader.java - Added check for join type, and then generate = ANSI joins or Oracle joins. Gavin, if this sounds alright to you, and doesn't conflict with your = refactoring, then I will check this in. Thanks, Jon... |
From: Jon L. <jon...@xe...> - 2002-09-24 13:41:56
|
Hi Chris, Yes, that was my initial thought however I thought it would complicate = things even more to move the join implementation into the Dialects. The = first thing is that we would need two Oracle dialects, one for Oracle 8, = and one for Oracle 9 since Oracle 9 *CAN* use ANSI style outer joins. = The other thing is that the SQL statements are genererated a little = differently between the two join styles. That would then move some of = the SQL generation into the dialects, so I decided to leave it in the = Loader classes. Perhaps Gavin has a better idea than using the Environment variable.?.? = Jon... ----- Original Message -----=20 From: Christoph Sturm=20 To: Jon Lipsky ; hib...@li...=20 Sent: Tuesday, September 24, 2002 3:20 PM Subject: Re: [Hibernate] Oracle Style Joins Implemented Hey Jon! Oracle Outer Joins are great, I have been needing this for quite some = time :) But wouldnt it be better to let the database Dialect decide what kind = of outer joins is generated instead of introducing a new parameter? regards chris ----- Original Message -----=20 From: Jon Lipsky=20 To: hib...@li...=20 Sent: Tuesday, September 24, 2002 3:06 PM Subject: [Hibernate] Oracle Style Joins Implemented Hi, I've implemented outer join support for Oracle 8. (Oracle 9 = supports the ANSI style outer joins.) I know Gavin is working on some refactoring right now, so I wanted = to make sure my work doesn't interfere with his before I check the = patches in. In order to implement this, I had to modify the following = files (along with what I did): Environment.java - Added a "useOracleJoins" environment parameter Loader.java - Added helper methods to generate the additions to the = from and the where clause for the Joins CollectionLoader.java - Added check for join type, and then generate = ANSI joins or Oracle joins. EntityLoader.java - Added check for join type, and then generate = ANSI joins or Oracle joins. OneToManyLoader.java - Added check for join type, and then generate = ANSI joins or Oracle joins. Gavin, if this sounds alright to you, and doesn't conflict with your = refactoring, then I will check this in. Thanks, Jon... |
From: Gavin K. <ga...@ap...> - 2002-09-24 15:31:40
|
Yep, Dialects can now specify some default properties (which may be = overridden). That should help. Secondly, I approve of moving *some* SQL generation to the Dialect = subclasses. I have been moving in that direction. ----- Original Message -----=20 From: Jon Lipsky=20 To: Christoph Sturm ; hib...@li...=20 Sent: Tuesday, September 24, 2002 11:41 PM Subject: Re: [Hibernate] Oracle Style Joins Implemented Hi Chris, Yes, that was my initial thought however I thought it would complicate = things even more to move the join implementation into the Dialects. The = first thing is that we would need two Oracle dialects, one for Oracle 8, = and one for Oracle 9 since Oracle 9 *CAN* use ANSI style outer joins. = The other thing is that the SQL statements are genererated a little = differently between the two join styles. That would then move some of = the SQL generation into the dialects, so I decided to leave it in the = Loader classes. Perhaps Gavin has a better idea than using the Environment = variable.?.? =20 Jon... ----- Original Message -----=20 From: Christoph Sturm=20 To: Jon Lipsky ; hib...@li...=20 Sent: Tuesday, September 24, 2002 3:20 PM Subject: Re: [Hibernate] Oracle Style Joins Implemented Hey Jon! Oracle Outer Joins are great, I have been needing this for quite = some time :) But wouldnt it be better to let the database Dialect decide what = kind of outer joins is generated instead of introducing a new parameter? regards chris ----- Original Message -----=20 From: Jon Lipsky=20 To: hib...@li...=20 Sent: Tuesday, September 24, 2002 3:06 PM Subject: [Hibernate] Oracle Style Joins Implemented Hi, I've implemented outer join support for Oracle 8. (Oracle 9 = supports the ANSI style outer joins.) I know Gavin is working on some refactoring right now, so I wanted = to make sure my work doesn't interfere with his before I check the = patches in. In order to implement this, I had to modify the following = files (along with what I did): Environment.java - Added a "useOracleJoins" environment parameter Loader.java - Added helper methods to generate the additions to = the from and the where clause for the Joins CollectionLoader.java - Added check for join type, and then = generate ANSI joins or Oracle joins. EntityLoader.java - Added check for join type, and then generate = ANSI joins or Oracle joins. OneToManyLoader.java - Added check for join type, and then = generate ANSI joins or Oracle joins. Gavin, if this sounds alright to you, and doesn't conflict with = your refactoring, then I will check this in. Thanks, Jon... |