You can subscribe to this list here.
2003 |
Jan
|
Feb
|
Mar
|
Apr
|
May
(32) |
Jun
(175) |
Jul
(209) |
Aug
(302) |
Sep
(287) |
Oct
(339) |
Nov
(314) |
Dec
(329) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2004 |
Jan
(479) |
Feb
(389) |
Mar
(599) |
Apr
(307) |
May
(390) |
Jun
(300) |
Jul
(410) |
Aug
(458) |
Sep
(299) |
Oct
(315) |
Nov
(363) |
Dec
(529) |
2005 |
Jan
(568) |
Feb
(434) |
Mar
(1004) |
Apr
(823) |
May
(767) |
Jun
(763) |
Jul
(854) |
Aug
(862) |
Sep
(560) |
Oct
(853) |
Nov
(763) |
Dec
(731) |
2006 |
Jan
(776) |
Feb
(608) |
Mar
(657) |
Apr
(424) |
May
(559) |
Jun
(440) |
Jul
(448) |
Aug
(58) |
Sep
|
Oct
(17) |
Nov
(16) |
Dec
(8) |
2007 |
Jan
(1) |
Feb
(8) |
Mar
(2) |
Apr
(5) |
May
(3) |
Jun
(3) |
Jul
(3) |
Aug
(16) |
Sep
(10) |
Oct
(4) |
Nov
(4) |
Dec
(4) |
2008 |
Jan
(8) |
Feb
(1) |
Mar
(1) |
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
(1) |
Oct
|
Nov
|
Dec
|
2009 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
(1) |
Oct
|
Nov
|
Dec
|
From: <leg...@at...> - 2003-08-04 14:01:14
|
The following comment has been added to this issue: Author: Gavin King Created: Mon, 4 Aug 2003 9:00 AM Body: I think you're being too specific here! Don't think only about prefixes - that is just one application! For example, I might want to change the class name com.package.FooBar to the table name PACKAGE_FOO_BAR. And also consider whether you _really_ want to pass column names to the same method as property names, and table names to the same method as class names. I think a NamingStrategy might need to handle properties w/o column mappings differently to mapped column names. --------------------------------------------------------------------- View the issue: http://opensource.atlassian.com/projects/hibernate/secure/ViewIssue.jspa?key=HB-227 Here is an overview of the issue: --------------------------------------------------------------------- Key: HB-227 Summary: NamingStrategy / prefix support for database objects Type: New Feature Status: Unassigned Priority: Minor Project: Hibernate2 Components: core Versions: 2.0.2 Assignee: Reporter: Timo Verhoeven Created: Mon, 4 Aug 2003 6:29 AM Updated: Mon, 4 Aug 2003 6:29 AM Description: Initial feature idea from mailing list: Hi all! When I design database datamodels I usually encounter clashes between reserved names and names I'd like to use for my tables/columns, e.g. "user", "role", etc.. So I ended up prefixing all tables/views/columns: Tables have a "tbl" prefix, views a "qry" prefix and columns either have a "fld" or a prefix based on the datatype ("txt"/"str" for varchars, etc.). I like to keep my mapping files small (/ to have few xdoclet tags) and like the fact that hibernate has smart default for column names: it uses the property's name. Would it be possible/would you consider it useful to be able to specify "default prefixes" for tables/columns so that I don't have to name my columns manually in my mappings when I have to use prefixes? Such settings could go into the SessionFactory configuration. Opinions? Timo --------------------------------------------------------------------- JIRA INFORMATION: This message is automatically generated by JIRA. If you think it was sent incorrectly contact one of the administrators: http://opensource.atlassian.com/projects/hibernate/secure/Administrators.jspa If you want more information on JIRA, or have a bug to report see: http://www.atlassian.com/software/jira |
From: <leg...@at...> - 2003-08-04 12:04:15
|
The following comment has been added to this issue: Author: Mathias Bogaert Created: Mon, 4 Aug 2003 7:02 AM Body: ahem, should have been session.delete(session.createCriteria(Dg.class).list()); --------------------------------------------------------------------- View the issue: http://opensource.atlassian.com/projects/hibernate/secure/ViewIssue.jspa?key=HB-228 Here is an overview of the issue: --------------------------------------------------------------------- Key: HB-228 Summary: Support deleting collections Type: Improvement Status: Unassigned Priority: Major Project: Hibernate2 Components: core Versions: 2.1 Assignee: Reporter: Mathias Bogaert Created: Mon, 4 Aug 2003 7:02 AM Updated: Mon, 4 Aug 2003 7:02 AM Environment: Hibernate 2.0.2 Description: It would be really cool if one could do this: session.delete(pm.getSession().createCriteria(Dg.class).list()); --------------------------------------------------------------------- JIRA INFORMATION: This message is automatically generated by JIRA. If you think it was sent incorrectly contact one of the administrators: http://opensource.atlassian.com/projects/hibernate/secure/Administrators.jspa If you want more information on JIRA, or have a bug to report see: http://www.atlassian.com/software/jira |
From: <leg...@at...> - 2003-08-04 12:04:15
|
Message: A new issue has been created in JIRA. --------------------------------------------------------------------- View the issue: http://opensource.atlassian.com/projects/hibernate/secure/ViewIssue.jspa?key=HB-228 Here is an overview of the issue: --------------------------------------------------------------------- Key: HB-228 Summary: Support deleting collections Type: Improvement Status: Unassigned Priority: Major Project: Hibernate2 Components: core Versions: 2.1 Assignee: Reporter: Mathias Bogaert Created: Mon, 4 Aug 2003 7:02 AM Updated: Mon, 4 Aug 2003 7:02 AM Environment: Hibernate 2.0.2 Description: It would be really cool if one could do this: session.delete(pm.getSession().createCriteria(Dg.class).list()); --------------------------------------------------------------------- JIRA INFORMATION: This message is automatically generated by JIRA. If you think it was sent incorrectly contact one of the administrators: http://opensource.atlassian.com/projects/hibernate/secure/Administrators.jspa If you want more information on JIRA, or have a bug to report see: http://www.atlassian.com/software/jira |
From: <leg...@at...> - 2003-08-04 11:45:14
|
The following comment has been added to this issue: Author: Timo Verhoeven Created: Mon, 4 Aug 2003 6:44 AM Body: Proposal: (*) add a package net.sf.hibernate.namingstrategy for the following classes (*) create an abstract root class NamingStrategy String getPrefixedColumnName(String columnName, Type columnType) String getPrefixedTableName(String tableName) String getPrefixedSequenceName(String sequenceName) String getPrefixedXXXName(...) // What am I missing here? Comments? (*) create a DefaultNamingStrategy class, which returns parameters unchanged (*) create a SimpleNamingStrategy prefixing tables with "tbl", columns with "fld", and sequences with "gen" (*) create a TypeNameStrategy prefixing tables with "tbl", sequences with "gen", and columns with a type based prefix ("int" for Integers, ...) (*) introduce a mappingStrategy attribute to the <hibernate-mapping> tag, respectively add a property to the Configuration; both of which may be omitted/unset - the DefaultNamingStrategy is used then (*) modify existing Hibernate classes in packages .mapping and .cfg to make them use NamingStrategies I'm currently biased towards prefixing "default names" (i.e. column attribute not given and the property name is used) AND names provided by the user. Otherwise it would not be possible to switch the naming strategy on the fly, because user provided names would have to be manually prefixed to a SINGLE naming strategy to "fit in". Opinions, comments? --------------------------------------------------------------------- View the issue: http://opensource.atlassian.com/projects/hibernate/secure/ViewIssue.jspa?key=HB-227 Here is an overview of the issue: --------------------------------------------------------------------- Key: HB-227 Summary: NamingStrategy / prefix support for database objects Type: New Feature Status: Unassigned Priority: Minor Project: Hibernate2 Components: core Versions: 2.0.2 Assignee: Reporter: Timo Verhoeven Created: Mon, 4 Aug 2003 6:29 AM Updated: Mon, 4 Aug 2003 6:29 AM Description: Initial feature idea from mailing list: Hi all! When I design database datamodels I usually encounter clashes between reserved names and names I'd like to use for my tables/columns, e.g. "user", "role", etc.. So I ended up prefixing all tables/views/columns: Tables have a "tbl" prefix, views a "qry" prefix and columns either have a "fld" or a prefix based on the datatype ("txt"/"str" for varchars, etc.). I like to keep my mapping files small (/ to have few xdoclet tags) and like the fact that hibernate has smart default for column names: it uses the property's name. Would it be possible/would you consider it useful to be able to specify "default prefixes" for tables/columns so that I don't have to name my columns manually in my mappings when I have to use prefixes? Such settings could go into the SessionFactory configuration. Opinions? Timo --------------------------------------------------------------------- JIRA INFORMATION: This message is automatically generated by JIRA. If you think it was sent incorrectly contact one of the administrators: http://opensource.atlassian.com/projects/hibernate/secure/Administrators.jspa If you want more information on JIRA, or have a bug to report see: http://www.atlassian.com/software/jira |
From: <leg...@at...> - 2003-08-04 11:32:14
|
The following comment has been added to this issue: Author: Timo Verhoeven Created: Mon, 4 Aug 2003 6:30 AM Body: Gavin's comment from the mailing list: Yes, I can certainly see the attraction - and it *has* been requested before. It would be nice to be able to plug in a something like: NamingStrategy strategy = new MyCustomNamingStrategy(); Configuration cfg = new Configuration(); cfg.setNamingStrategy(strategy); perhaps we could even allow this as: <hibernate-mapping naming="pkg.MyCustomNamingStrategy"> The naming strategy itself would have methods like: String getColumnName(String propertyName) String getTableName(String className) String overrideColumName(String columnName) String overrideTableName(String tableName) Add a feature request to JIRA! Note that this is *really* easy to do, with just a little bit of playing with the .cfg package. Why not implement it yourself, and send a patch? --------------------------------------------------------------------- View the issue: http://opensource.atlassian.com/projects/hibernate/secure/ViewIssue.jspa?key=HB-227 Here is an overview of the issue: --------------------------------------------------------------------- Key: HB-227 Summary: NamingStrategy / prefix support for database objects Type: New Feature Status: Unassigned Priority: Minor Project: Hibernate2 Components: core Versions: 2.0.2 Assignee: Reporter: Timo Verhoeven Created: Mon, 4 Aug 2003 6:29 AM Updated: Mon, 4 Aug 2003 6:29 AM Description: Initial feature idea from mailing list: Hi all! When I design database datamodels I usually encounter clashes between reserved names and names I'd like to use for my tables/columns, e.g. "user", "role", etc.. So I ended up prefixing all tables/views/columns: Tables have a "tbl" prefix, views a "qry" prefix and columns either have a "fld" or a prefix based on the datatype ("txt"/"str" for varchars, etc.). I like to keep my mapping files small (/ to have few xdoclet tags) and like the fact that hibernate has smart default for column names: it uses the property's name. Would it be possible/would you consider it useful to be able to specify "default prefixes" for tables/columns so that I don't have to name my columns manually in my mappings when I have to use prefixes? Such settings could go into the SessionFactory configuration. Opinions? Timo --------------------------------------------------------------------- JIRA INFORMATION: This message is automatically generated by JIRA. If you think it was sent incorrectly contact one of the administrators: http://opensource.atlassian.com/projects/hibernate/secure/Administrators.jspa If you want more information on JIRA, or have a bug to report see: http://www.atlassian.com/software/jira |
From: <leg...@at...> - 2003-08-04 11:30:26
|
Message: A new issue has been created in JIRA. --------------------------------------------------------------------- View the issue: http://opensource.atlassian.com/projects/hibernate/secure/ViewIssue.jspa?key=HB-227 Here is an overview of the issue: --------------------------------------------------------------------- Key: HB-227 Summary: NamingStrategy / prefix support for database objects Type: New Feature Status: Unassigned Priority: Minor Project: Hibernate2 Components: core Versions: 2.0.2 Assignee: Reporter: Timo Verhoeven Created: Mon, 4 Aug 2003 6:29 AM Updated: Mon, 4 Aug 2003 6:29 AM Description: Initial feature idea from mailing list: Hi all! When I design database datamodels I usually encounter clashes between reserved names and names I'd like to use for my tables/columns, e.g. "user", "role", etc.. So I ended up prefixing all tables/views/columns: Tables have a "tbl" prefix, views a "qry" prefix and columns either have a "fld" or a prefix based on the datatype ("txt"/"str" for varchars, etc.). I like to keep my mapping files small (/ to have few xdoclet tags) and like the fact that hibernate has smart default for column names: it uses the property's name. Would it be possible/would you consider it useful to be able to specify "default prefixes" for tables/columns so that I don't have to name my columns manually in my mappings when I have to use prefixes? Such settings could go into the SessionFactory configuration. Opinions? Timo --------------------------------------------------------------------- JIRA INFORMATION: This message is automatically generated by JIRA. If you think it was sent incorrectly contact one of the administrators: http://opensource.atlassian.com/projects/hibernate/secure/Administrators.jspa If you want more information on JIRA, or have a bug to report see: http://www.atlassian.com/software/jira |
From: <leg...@at...> - 2003-08-04 11:30:16
|
Message: The following issue has been closed. Resolver: Gavin King Date: Mon, 4 Aug 2003 6:29 AM I have applied this patch to both branches. Thanks! (If you do any further work in this area, please work against v21branch CVS branch.) --------------------------------------------------------------------- View the issue: http://opensource.atlassian.com/projects/hibernate/secure/ViewIssue.jspa?key=HB-117 Here is an overview of the issue: --------------------------------------------------------------------- Key: HB-117 Summary: Support for more SQL functions in SELECT Type: Improvement Status: Closed Priority: Major Resolution: FIXED Project: Hibernate2 Components: core Fix Fors: 2.0.3 2.1 beta 1 Assignee: David Channon Reporter: Gavin King Created: Sun, 1 Jun 2003 7:58 PM Updated: Mon, 4 Aug 2003 6:29 AM Description: Currently, Hibernate supports exactly five (hardcoded) SQL functions in the HQL SELECT clause. They are the aggregate functions COUNT(), AVG(), SUM(), MIN(), MAX() A number of users would like to be able to specify an arbitrary SQL function in the SELECT. The problem here is that we need to know the return type of the function to be able to read it from the result set. I propose that the Dialect classes include a collection of mappings from function names to Hibernate types (eg. CURRENT_DATE -> Hibernate.DATE). That way, we can support the most commonly used SQL functions, and others can be easily added by users providing extensions to the Dialect. So, we would like to allow: SELECT CURRENT_DATE(), TRUNC(foo.amount), ...... --------------------------------------------------------------------- JIRA INFORMATION: This message is automatically generated by JIRA. If you think it was sent incorrectly contact one of the administrators: http://opensource.atlassian.com/projects/hibernate/secure/Administrators.jspa If you want more information on JIRA, or have a bug to report see: http://www.atlassian.com/software/jira |
From: <leg...@at...> - 2003-08-04 08:58:14
|
The following issue has been updated: Updater: David Channon (mailto:dch...@bi...) Date: Mon, 4 Aug 2003 3:57 AM Comment: Patch for seven existing files and introducting two new files. Changes: Attachment changed to HB117-Patch.txt --------------------------------------------------------------------- For a full history of the issue, see: http://opensource.atlassian.com/projects/hibernate/secure/ViewIssue.jspa?key=HB-117&page=history --------------------------------------------------------------------- View the issue: http://opensource.atlassian.com/projects/hibernate/secure/ViewIssue.jspa?key=HB-117 Here is an overview of the issue: --------------------------------------------------------------------- Key: HB-117 Summary: Support for more SQL functions in SELECT Type: Improvement Status: In Progress Priority: Major Project: Hibernate2 Components: core Assignee: David Channon Reporter: Gavin King Created: Sun, 1 Jun 2003 7:58 PM Updated: Mon, 4 Aug 2003 3:57 AM Description: Currently, Hibernate supports exactly five (hardcoded) SQL functions in the HQL SELECT clause. They are the aggregate functions COUNT(), AVG(), SUM(), MIN(), MAX() A number of users would like to be able to specify an arbitrary SQL function in the SELECT. The problem here is that we need to know the return type of the function to be able to read it from the result set. I propose that the Dialect classes include a collection of mappings from function names to Hibernate types (eg. CURRENT_DATE -> Hibernate.DATE). That way, we can support the most commonly used SQL functions, and others can be easily added by users providing extensions to the Dialect. So, we would like to allow: SELECT CURRENT_DATE(), TRUNC(foo.amount), ...... --------------------------------------------------------------------- JIRA INFORMATION: This message is automatically generated by JIRA. If you think it was sent incorrectly contact one of the administrators: http://opensource.atlassian.com/projects/hibernate/secure/Administrators.jspa If you want more information on JIRA, or have a bug to report see: http://www.atlassian.com/software/jira |
From: <leg...@at...> - 2003-08-04 08:56:14
|
The following comment has been added to this issue: Author: David Channon Created: Mon, 4 Aug 2003 3:55 AM Body: While doing further testing I decided to expand the scope of the functionality. All of the above plus below. NOTE: I have added Dialect functions only to Oracle thus these examples only apply to the Oracle Dialect (at the moment). Extra since last comment. * The parser can deal with no argument functions with and without parenthesis. This was required for Oracle as its current date function is sysdate with no parenthesis and other databases use empty pair of parenthesis. For example. select s.name, sysdate, trunc(s.pay), round(s.pay) from s in class Simple * Nesting of functions is now allowed. For example: select abs(round(s.pay)) from s in class Simple select trunc(round(sysdate)) from s in class Simple It is very easy to add functions to your Dialect of choice. I have attached a patch(s). --------------------------------------------------------------------- View the issue: http://opensource.atlassian.com/projects/hibernate/secure/ViewIssue.jspa?key=HB-117 Here is an overview of the issue: --------------------------------------------------------------------- Key: HB-117 Summary: Support for more SQL functions in SELECT Type: Improvement Status: In Progress Priority: Major Project: Hibernate2 Components: core Assignee: David Channon Reporter: Gavin King Created: Sun, 1 Jun 2003 7:58 PM Updated: Mon, 9 Jun 2003 6:44 AM Description: Currently, Hibernate supports exactly five (hardcoded) SQL functions in the HQL SELECT clause. They are the aggregate functions COUNT(), AVG(), SUM(), MIN(), MAX() A number of users would like to be able to specify an arbitrary SQL function in the SELECT. The problem here is that we need to know the return type of the function to be able to read it from the result set. I propose that the Dialect classes include a collection of mappings from function names to Hibernate types (eg. CURRENT_DATE -> Hibernate.DATE). That way, we can support the most commonly used SQL functions, and others can be easily added by users providing extensions to the Dialect. So, we would like to allow: SELECT CURRENT_DATE(), TRUNC(foo.amount), ...... --------------------------------------------------------------------- JIRA INFORMATION: This message is automatically generated by JIRA. If you think it was sent incorrectly contact one of the administrators: http://opensource.atlassian.com/projects/hibernate/secure/Administrators.jspa If you want more information on JIRA, or have a bug to report see: http://www.atlassian.com/software/jira |
From: <leg...@at...> - 2003-08-04 08:54:14
|
Message: The following issue has been closed. Resolver: Gavin King Date: Mon, 4 Aug 2003 3:53 AM In fact, to do this, you are meant to map the "discriminator" property with insert="false" update="false". This was always the case. I'm amazed that you got away with it before.... --------------------------------------------------------------------- View the issue: http://opensource.atlassian.com/projects/hibernate/secure/ViewIssue.jspa?key=HB-226 Here is an overview of the issue: --------------------------------------------------------------------- Key: HB-226 Summary: Duplicate column error reported for discriminator Type: Bug Status: Closed Priority: Critical Resolution: REJECTED Project: Hibernate2 Components: core Versions: 2.0.2 Assignee: Reporter: Tomislav Bodor Created: Mon, 4 Aug 2003 12:27 AM Updated: Mon, 4 Aug 2003 3:53 AM Environment: Not specific to operating system or particular environment Description: It appears that one of the changes in version 2.0.2 was to add a check for repeated column mappings. Unfortunately, declaring a discriminator column counts as mapping, though it does not make the column available in the mapped entity. If such a mapping is added using the property tag, a "Repeated column in mapping..." error is reported. Upon checking in the CVS repository, the change was made to EntityPersister class, between versions 1.35 and 1.36, to add ckecks for duplicate column mappings. This was relaxed in 1.37, but not sufficiently. It appears that line 703 (in 2.0.2) should be removed: distinctColumns.add(discriminatorColumnName); This issue makes it impossible to map an inheritance hierarchy to a single table and still have the discriminator available through a getter method in the mapped entity. Could someone please confirm this and issue a fix or suggest a workaround? Regards, Tomislav --------------------------------------------------------------------- JIRA INFORMATION: This message is automatically generated by JIRA. If you think it was sent incorrectly contact one of the administrators: http://opensource.atlassian.com/projects/hibernate/secure/Administrators.jspa If you want more information on JIRA, or have a bug to report see: http://www.atlassian.com/software/jira |
From: <leg...@at...> - 2003-08-04 05:27:14
|
Message: A new issue has been created in JIRA. --------------------------------------------------------------------- View the issue: http://opensource.atlassian.com/projects/hibernate/secure/ViewIssue.jspa?key=HB-226 Here is an overview of the issue: --------------------------------------------------------------------- Key: HB-226 Summary: Duplicate column error reported for discriminator Type: Bug Status: Unassigned Priority: Critical Project: Hibernate2 Components: core Versions: 2.0.2 Assignee: Reporter: Tomislav Bodor Created: Mon, 4 Aug 2003 12:27 AM Updated: Mon, 4 Aug 2003 12:27 AM Environment: Not specific to operating system or particular environment Description: It appears that one of the changes in version 2.0.2 was to add a check for repeated column mappings. Unfortunately, declaring a discriminator column counts as mapping, though it does not make the column available in the mapped entity. If such a mapping is added using the property tag, a "Repeated column in mapping..." error is reported. Upon checking in the CVS repository, the change was made to EntityPersister class, between versions 1.35 and 1.36, to add ckecks for duplicate column mappings. This was relaxed in 1.37, but not sufficiently. It appears that line 703 (in 2.0.2) should be removed: distinctColumns.add(discriminatorColumnName); This issue makes it impossible to map an inheritance hierarchy to a single table and still have the discriminator available through a getter method in the mapped entity. Could someone please confirm this and issue a fix or suggest a workaround? Regards, Tomislav --------------------------------------------------------------------- JIRA INFORMATION: This message is automatically generated by JIRA. If you think it was sent incorrectly contact one of the administrators: http://opensource.atlassian.com/projects/hibernate/secure/Administrators.jspa If you want more information on JIRA, or have a bug to report see: http://www.atlassian.com/software/jira |
From: <leg...@at...> - 2003-08-03 15:41:14
|
Message: The following issue has been closed. Resolver: Gavin King Date: Sun, 3 Aug 2003 10:40 AM I applied this patch to the 2.1 branch. Thanks! --------------------------------------------------------------------- View the issue: http://opensource.atlassian.com/projects/hibernate/secure/ViewIssue.jspa?key=HB-146 Here is an overview of the issue: --------------------------------------------------------------------- Key: HB-146 Summary: Eliminate array creation for single column queries Type: Patch Status: Closed Priority: Minor Resolution: FIXED Project: Hibernate2 Components: core Fix Fors: 2.1 beta 1 Versions: 2.0.1 Assignee: Gavin King Reporter: Chris Nokleberg Created: Fri, 20 Jun 2003 1:11 AM Updated: Sun, 3 Aug 2003 10:40 AM Description: IteratorImpl currently created a new Object[] for each row returned from a query. For single column queries the iterator then just pulls the single value out of the array before returning it. This patch removes the array creation for single column queries. BTW, why was the decision made to use a new array for each row? Even in the case of multiple value queries, it would be much more efficient to reuse the same array. The user could copy the values into a new array if so desired. It's probably too late to change this, unfortunately... --------------------------------------------------------------------- JIRA INFORMATION: This message is automatically generated by JIRA. If you think it was sent incorrectly contact one of the administrators: http://opensource.atlassian.com/projects/hibernate/secure/Administrators.jspa If you want more information on JIRA, or have a bug to report see: http://www.atlassian.com/software/jira |
From: <leg...@at...> - 2003-08-03 14:16:14
|
The following comment has been added to this issue: Author: Gavin King Created: Sun, 3 Aug 2003 9:15 AM Body: Ace! Fantastic :) Ummmm .... are you submitting a patch for this? --------------------------------------------------------------------- View the issue: http://opensource.atlassian.com/projects/hibernate/secure/ViewIssue.jspa?key=HB-117 Here is an overview of the issue: --------------------------------------------------------------------- Key: HB-117 Summary: Support for more SQL functions in SELECT Type: Improvement Status: In Progress Priority: Major Project: Hibernate2 Components: core Assignee: David Channon Reporter: Gavin King Created: Sun, 1 Jun 2003 7:58 PM Updated: Mon, 9 Jun 2003 6:44 AM Description: Currently, Hibernate supports exactly five (hardcoded) SQL functions in the HQL SELECT clause. They are the aggregate functions COUNT(), AVG(), SUM(), MIN(), MAX() A number of users would like to be able to specify an arbitrary SQL function in the SELECT. The problem here is that we need to know the return type of the function to be able to read it from the result set. I propose that the Dialect classes include a collection of mappings from function names to Hibernate types (eg. CURRENT_DATE -> Hibernate.DATE). That way, we can support the most commonly used SQL functions, and others can be easily added by users providing extensions to the Dialect. So, we would like to allow: SELECT CURRENT_DATE(), TRUNC(foo.amount), ...... --------------------------------------------------------------------- JIRA INFORMATION: This message is automatically generated by JIRA. If you think it was sent incorrectly contact one of the administrators: http://opensource.atlassian.com/projects/hibernate/secure/Administrators.jspa If you want more information on JIRA, or have a bug to report see: http://www.atlassian.com/software/jira |
From: <leg...@at...> - 2003-08-03 14:06:14
|
The following comment has been added to this issue: Author: David Channon Created: Sun, 3 Aug 2003 9:05 AM Body: The initial cut for this change has been completed. What I have done: * Moved the hard coded aggregate functions into the base Dialect. * Added the facility of other Dialects to add Dialect specific functions. In my case I have change the Oracle9i Dialect by adding trunc, sysdate, and other functions * Modified the SelectParser to simplify parsing of aggregate functions. No longer have special cases for count or avg functions. * Added an interface and general class for suppling the return type of the function. * Added an extra test(s) to SQLFunctionTest Given I have added extra functions to the Oracle dialect you can now use extra select functions such as.. select sysdate, trunc(s.value) from s as class simple --------------------------------------------------------------------- View the issue: http://opensource.atlassian.com/projects/hibernate/secure/ViewIssue.jspa?key=HB-117 Here is an overview of the issue: --------------------------------------------------------------------- Key: HB-117 Summary: Support for more SQL functions in SELECT Type: Improvement Status: In Progress Priority: Major Project: Hibernate2 Components: core Assignee: David Channon Reporter: Gavin King Created: Sun, 1 Jun 2003 7:58 PM Updated: Mon, 9 Jun 2003 6:44 AM Description: Currently, Hibernate supports exactly five (hardcoded) SQL functions in the HQL SELECT clause. They are the aggregate functions COUNT(), AVG(), SUM(), MIN(), MAX() A number of users would like to be able to specify an arbitrary SQL function in the SELECT. The problem here is that we need to know the return type of the function to be able to read it from the result set. I propose that the Dialect classes include a collection of mappings from function names to Hibernate types (eg. CURRENT_DATE -> Hibernate.DATE). That way, we can support the most commonly used SQL functions, and others can be easily added by users providing extensions to the Dialect. So, we would like to allow: SELECT CURRENT_DATE(), TRUNC(foo.amount), ...... --------------------------------------------------------------------- JIRA INFORMATION: This message is automatically generated by JIRA. If you think it was sent incorrectly contact one of the administrators: http://opensource.atlassian.com/projects/hibernate/secure/Administrators.jspa If you want more information on JIRA, or have a bug to report see: http://www.atlassian.com/software/jira |
From: <leg...@at...> - 2003-08-03 07:09:13
|
Message: The following issue has been closed. Resolver: Gavin King Date: Sun, 3 Aug 2003 2:08 AM This is now implemented, as: select mapElement from Foo foo join foo.map mapElement where index(mapElement) = 'foo' The index() function may even appear in the select clause. Note that path expressions with [] may still not appear in the select or from clauses. --------------------------------------------------------------------- View the issue: http://opensource.atlassian.com/projects/hibernate/secure/ViewIssue.jspa?key=HB-38 Here is an overview of the issue: --------------------------------------------------------------------- Key: HB-38 Summary: HQL access to collection members by [index] Type: Improvement Status: Closed Priority: Major Resolution: FIXED Project: Hibernate2 Fix Fors: 2.1 Assignee: Gavin King Reporter: Max Rydahl Andersen Created: Sat, 3 May 2003 10:23 AM Updated: Sun, 3 Aug 2003 2:08 AM Description: HQL access to collection members Please extend HQL to allow access to instances mapped to collections, something like this: if names is a list: "select e.names[0] from e in class Element" if names is a map: "select e.names("primary") from e in class Element" Null should be returned if either lookup fails. http://sourceforge.net/tracker/index.php?func=detail&aid=729882&group_id=40712&atid=428711 --------------------------------------------------------------------- JIRA INFORMATION: This message is automatically generated by JIRA. If you think it was sent incorrectly contact one of the administrators: http://opensource.atlassian.com/projects/hibernate/secure/Administrators.jspa If you want more information on JIRA, or have a bug to report see: http://www.atlassian.com/software/jira |
From: <leg...@at...> - 2003-08-03 01:25:14
|
Message: The following issue has been closed. Resolver: Gavin King Date: Sat, 2 Aug 2003 8:24 PM implementing this for <joined-subclass>es and <component>s is a bit trickier - if anyone needs this, they can submit it as a new JIRA issue --------------------------------------------------------------------- View the issue: http://opensource.atlassian.com/projects/hibernate/secure/ViewIssue.jspa?key=HB-111 Here is an overview of the issue: --------------------------------------------------------------------- Key: HB-111 Summary: fields defined as formulas... Type: New Feature Status: Closed Priority: Minor Resolution: FIXED Project: Hibernate2 Components: core Fix Fors: 2.0.2 Versions: 2.0rc2 Assignee: Gavin King Reporter: Fabio Parise Created: Thu, 29 May 2003 4:58 AM Updated: Sat, 2 Aug 2003 8:24 PM Description: Trying to define a computed field (i.e. 'status1000' as the result of the following computation: status+1000; where 'status' is a table column) in this way: <property column="STATUS+1000" length="10" name="status1000" not-null="true" type="java.lang.Long" update="false" insert="false"/> if the first 7 chars of the attribute 'column' contains some non-valid chars for sql aliases, the produced SELECT statement will fail. In the example the alias for the computed field is 'STATUS+16_', which is not a valid sql alias. SELECT WkfPr0_.pkid as pkid, ..., WkfPr0_.STATUS+1000 as STATUS+16_ FROM WKF_PROCESS_CLASS WkfPr0_ WHERE WkfPr0_.pkid=? if the field involved in the formula has a longer name i.e. MYSTATUS --> formula=MYSTATUS+1000, the computed alias is MYSTATU16_, which is a valid alias. --------------------------------------------------------------------- JIRA INFORMATION: This message is automatically generated by JIRA. If you think it was sent incorrectly contact one of the administrators: http://opensource.atlassian.com/projects/hibernate/secure/Administrators.jspa If you want more information on JIRA, or have a bug to report see: http://www.atlassian.com/software/jira |
From: <leg...@at...> - 2003-08-03 01:23:14
|
Message: The following issue has been closed. Resolver: Gavin King Date: Sat, 2 Aug 2003 8:22 PM Yeah, thanks .... I thought about doing this myself. In CVS (with a slight adjustment) --------------------------------------------------------------------- View the issue: http://opensource.atlassian.com/projects/hibernate/secure/ViewIssue.jspa?key=HB-225 Here is an overview of the issue: --------------------------------------------------------------------- Key: HB-225 Summary: Inform about disabling cglib to get better help in exception message Type: Patch Status: Closed Priority: Minor Resolution: FIXED Project: Hibernate2 Components: core Fix Fors: 2.0.3 Versions: 2.1 Assignee: Gavin King Reporter: Max Rydahl Andersen Created: Sat, 2 Aug 2003 7:42 PM Updated: Sat, 2 Aug 2003 8:22 PM Description: Just letting the user know that he can be informed about which property that has the error if he disables the optimizer. Index: AbstractEntityPersister.java =================================================================== RCS file: /cvsroot/hibernate/Hibernate2/src/net/sf/hibernate/persister/AbstractEntityPersister.java,v retrieving revision 1.33 diff -u -r1.33 AbstractEntityPersister.java --- AbstractEntityPersister.java 20 Jul 2003 03:18:49 -0000 1.33 +++ AbstractEntityPersister.java 3 Aug 2003 00:39:38 -0000 @@ -164,7 +164,7 @@ } } catch (Throwable t) { - throw new PropertyAccessException(t, "exception setting property value with CGLIB", true, mappedClass, "?"); + throw new PropertyAccessException(t, "exception setting property value with CGLIB. Disable CGLIB optimizer to get the related property name (-Dhibernate.cglib.use_reflection_optimizer=true) .", true, mappedClass, "?"); } for (int j=0; j<hydrateSpan; j++) getSetters()[j].set(object, values[j]); --------------------------------------------------------------------- JIRA INFORMATION: This message is automatically generated by JIRA. If you think it was sent incorrectly contact one of the administrators: http://opensource.atlassian.com/projects/hibernate/secure/Administrators.jspa If you want more information on JIRA, or have a bug to report see: http://www.atlassian.com/software/jira |
From: <leg...@at...> - 2003-08-03 01:05:14
|
The following comment has been added to this issue: Author: Max Rydahl Andersen Created: Sat, 2 Aug 2003 8:05 PM Body: here is a patch that also include the warning for getters ;) Index: AbstractEntityPersister.java =================================================================== RCS file: /cvsroot/hibernate/Hibernate2/src/net/sf/hibernate/persister/AbstractEntityPersister.java,v retrieving revision 1.33 diff -u -r1.33 AbstractEntityPersister.java --- AbstractEntityPersister.java 20 Jul 2003 03:18:49 -0000 1.33 +++ AbstractEntityPersister.java 3 Aug 2003 01:04:38 -0000 @@ -164,7 +164,7 @@ } } catch (Throwable t) { - throw new PropertyAccessException(t, "exception setting property value with CGLIB", true, mappedClass, "?"); + throw new PropertyAccessException(t, "exception setting property value with CGLIB. Disable CGLIB optimizer to get the related property name (-Dhibernate.cglib.use_reflection_optimizer=true).", true, mappedClass, "?"); } for (int j=0; j<hydrateSpan; j++) getSetters()[j].set(object, values[j]); @@ -180,7 +180,7 @@ } } catch (Throwable t) { - throw new PropertyAccessException(t, "exception getting property value with CGLIB", false, mappedClass, "?"); + throw new PropertyAccessException(t, "exception getting property value with CGLIB. Disable CGLIB optimizer to get the related property name (-Dhibernate.cglib.use_reflection_optimizer=true).", false, mappedClass, "?"); } Object[] result = new Object[hydrateSpan]; --------------------------------------------------------------------- View the issue: http://opensource.atlassian.com/projects/hibernate/secure/ViewIssue.jspa?key=HB-225 Here is an overview of the issue: --------------------------------------------------------------------- Key: HB-225 Summary: Inform about disabling cglib to get better help in exception message Type: Patch Status: Assigned Priority: Minor Project: Hibernate2 Components: core Versions: 2.1 Assignee: Gavin King Reporter: Max Rydahl Andersen Created: Sat, 2 Aug 2003 7:42 PM Updated: Sat, 2 Aug 2003 7:42 PM Description: Just letting the user know that he can be informed about which property that has the error if he disables the optimizer. Index: AbstractEntityPersister.java =================================================================== RCS file: /cvsroot/hibernate/Hibernate2/src/net/sf/hibernate/persister/AbstractEntityPersister.java,v retrieving revision 1.33 diff -u -r1.33 AbstractEntityPersister.java --- AbstractEntityPersister.java 20 Jul 2003 03:18:49 -0000 1.33 +++ AbstractEntityPersister.java 3 Aug 2003 00:39:38 -0000 @@ -164,7 +164,7 @@ } } catch (Throwable t) { - throw new PropertyAccessException(t, "exception setting property value with CGLIB", true, mappedClass, "?"); + throw new PropertyAccessException(t, "exception setting property value with CGLIB. Disable CGLIB optimizer to get the related property name (-Dhibernate.cglib.use_reflection_optimizer=true) .", true, mappedClass, "?"); } for (int j=0; j<hydrateSpan; j++) getSetters()[j].set(object, values[j]); --------------------------------------------------------------------- JIRA INFORMATION: This message is automatically generated by JIRA. If you think it was sent incorrectly contact one of the administrators: http://opensource.atlassian.com/projects/hibernate/secure/Administrators.jspa If you want more information on JIRA, or have a bug to report see: http://www.atlassian.com/software/jira |
From: <leg...@at...> - 2003-08-03 00:54:14
|
Message: The following issue has been closed. Resolver: Gavin King Date: Sat, 2 Aug 2003 7:52 PM This was a bug in 2.0.1 that has been fixed. Download 2.0.2 (released 2 days ago). --------------------------------------------------------------------- View the issue: http://opensource.atlassian.com/projects/hibernate/secure/ViewIssue.jspa?key=HB-224 Here is an overview of the issue: --------------------------------------------------------------------- Key: HB-224 Summary: Querying collection within a component Type: Bug Status: Closed Priority: Minor Resolution: DUPLICATE Project: Hibernate2 Components: core Versions: 2.0.1 Assignee: Reporter: Rex Madden Created: Sat, 2 Aug 2003 12:35 PM Updated: Sat, 2 Aug 2003 7:52 PM Environment: Windows XP Description: I'm switching to 2.0.1 from 1.2.3. I received the following error trying to do a query on a collection that's within a component. Obviously, this used to work in 1.2.3. I've included part of my mapping below. Using elements(mov.cast.cast.list) did not help. net.sf.hibernate.QueryException: could not resolve property type: cast.cast.null [SELECT mov.id FROM mov in class Movie WHERE :findTarget in mov.component.list.elements] at net.sf.hibernate.hql.PathExpressionParser.getPropertyType(PathExpressionParser.java:223) at net.sf.hibernate.hql.PathExpressionParser.end(PathExpressionParser.java:270) at net.sf.hibernate.hql.WhereParser.preprocess(WhereParser.java:347) at net.sf.hibernate.hql.WhereParser.doPathExpression(WhereParser.java:355) at net.sf.hibernate.hql.WhereParser.doToken(WhereParser.java:389) at net.sf.hibernate.hql.WhereParser.token(WhereParser.java:275) at net.sf.hibernate.hql.ClauseParser.token(ClauseParser.java:73) at net.sf.hibernate.hql.PreprocessingParser.token(PreprocessingParser.java:120) at net.sf.hibernate.hql.ParserHelper.parse(ParserHelper.java:29) at net.sf.hibernate.hql.QueryTranslator.compile(QueryTranslator.java:145) at net.sf.hibernate.hql.QueryTranslator.compile(QueryTranslator.java:132) at net.sf.hibernate.impl.SessionFactoryImpl.getQuery(SessionFactoryImpl.java:373) at net.sf.hibernate.impl.SessionFactoryImpl.getQuery(SessionFactoryImpl.java:351) at net.sf.hibernate.impl.SessionImpl.getQueries(SessionImpl.java:1381) at net.sf.hibernate.impl.SessionImpl.find(SessionImpl.java:1345) at net.sf.hibernate.impl.QueryImpl.list(QueryImpl.java:76) at com.fetchaflick.videotest.ojb.FetchaQuery.list(FetchaQuery.java:45) at com.fetchaflick.videotest.movie.BaseMovieFinder.findPageBy(BaseMovieFinder.java:62) at com.fetchaflick.videotest.movie.BaseMovieFinder.findPageByActor(BaseMovieFinder.java:45) at com.fetchaflick.videotest.movie.MovieFinderTest.testFindByActor(MovieFinderTest.java:100) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) <class name="Movie" table="PRODUCT"> <component name="component" class="com.fetchaflick.videotest.movie.Cast"> <list name="list" table="MOVIE_CAST" cascade="all"> <jcs-cache usage="read-write"/> <key column="MOVIE_ID"/> <index column="POS"/> <element type="string" column="NAME"/> </list> </component> </class> Original thread on the forum http://sourceforge.net/forum/forum.php?thread_id=889001&forum_id=128638 I put this in JIRA a while ago, but I guess it lost it (and my account)? --------------------------------------------------------------------- JIRA INFORMATION: This message is automatically generated by JIRA. If you think it was sent incorrectly contact one of the administrators: http://opensource.atlassian.com/projects/hibernate/secure/Administrators.jspa If you want more information on JIRA, or have a bug to report see: http://www.atlassian.com/software/jira |
From: <leg...@at...> - 2003-08-03 00:43:17
|
Message: A new issue has been created in JIRA. --------------------------------------------------------------------- View the issue: http://opensource.atlassian.com/projects/hibernate/secure/ViewIssue.jspa?key=HB-225 Here is an overview of the issue: --------------------------------------------------------------------- Key: HB-225 Summary: Inform about disabling cglib to get better help in exception message Type: Patch Status: Assigned Priority: Minor Project: Hibernate2 Components: core Versions: 2.1 Assignee: Gavin King Reporter: Max Rydahl Andersen Created: Sat, 2 Aug 2003 7:42 PM Updated: Sat, 2 Aug 2003 7:42 PM Description: Just letting the user know that he can be informed about which property that has the error if he disables the optimizer. Index: AbstractEntityPersister.java =================================================================== RCS file: /cvsroot/hibernate/Hibernate2/src/net/sf/hibernate/persister/AbstractEntityPersister.java,v retrieving revision 1.33 diff -u -r1.33 AbstractEntityPersister.java --- AbstractEntityPersister.java 20 Jul 2003 03:18:49 -0000 1.33 +++ AbstractEntityPersister.java 3 Aug 2003 00:39:38 -0000 @@ -164,7 +164,7 @@ } } catch (Throwable t) { - throw new PropertyAccessException(t, "exception setting property value with CGLIB", true, mappedClass, "?"); + throw new PropertyAccessException(t, "exception setting property value with CGLIB. Disable CGLIB optimizer to get the related property name (-Dhibernate.cglib.use_reflection_optimizer=true) .", true, mappedClass, "?"); } for (int j=0; j<hydrateSpan; j++) getSetters()[j].set(object, values[j]); --------------------------------------------------------------------- JIRA INFORMATION: This message is automatically generated by JIRA. If you think it was sent incorrectly contact one of the administrators: http://opensource.atlassian.com/projects/hibernate/secure/Administrators.jspa If you want more information on JIRA, or have a bug to report see: http://www.atlassian.com/software/jira |
From: <leg...@at...> - 2003-08-02 17:35:14
|
Message: A new issue has been created in JIRA. --------------------------------------------------------------------- View the issue: http://opensource.atlassian.com/projects/hibernate/secure/ViewIssue.jspa?key=HB-224 Here is an overview of the issue: --------------------------------------------------------------------- Key: HB-224 Summary: Querying collection within a component Type: Bug Status: Unassigned Priority: Minor Project: Hibernate2 Components: core Versions: 2.0.1 Assignee: Reporter: Rex Madden Created: Sat, 2 Aug 2003 12:35 PM Updated: Sat, 2 Aug 2003 12:35 PM Environment: Windows XP Description: I'm switching to 2.0.1 from 1.2.3. I received the following error trying to do a query on a collection that's within a component. Obviously, this used to work in 1.2.3. I've included part of my mapping below. Using elements(mov.cast.cast.list) did not help. net.sf.hibernate.QueryException: could not resolve property type: cast.cast.null [SELECT mov.id FROM mov in class Movie WHERE :findTarget in mov.component.list.elements] at net.sf.hibernate.hql.PathExpressionParser.getPropertyType(PathExpressionParser.java:223) at net.sf.hibernate.hql.PathExpressionParser.end(PathExpressionParser.java:270) at net.sf.hibernate.hql.WhereParser.preprocess(WhereParser.java:347) at net.sf.hibernate.hql.WhereParser.doPathExpression(WhereParser.java:355) at net.sf.hibernate.hql.WhereParser.doToken(WhereParser.java:389) at net.sf.hibernate.hql.WhereParser.token(WhereParser.java:275) at net.sf.hibernate.hql.ClauseParser.token(ClauseParser.java:73) at net.sf.hibernate.hql.PreprocessingParser.token(PreprocessingParser.java:120) at net.sf.hibernate.hql.ParserHelper.parse(ParserHelper.java:29) at net.sf.hibernate.hql.QueryTranslator.compile(QueryTranslator.java:145) at net.sf.hibernate.hql.QueryTranslator.compile(QueryTranslator.java:132) at net.sf.hibernate.impl.SessionFactoryImpl.getQuery(SessionFactoryImpl.java:373) at net.sf.hibernate.impl.SessionFactoryImpl.getQuery(SessionFactoryImpl.java:351) at net.sf.hibernate.impl.SessionImpl.getQueries(SessionImpl.java:1381) at net.sf.hibernate.impl.SessionImpl.find(SessionImpl.java:1345) at net.sf.hibernate.impl.QueryImpl.list(QueryImpl.java:76) at com.fetchaflick.videotest.ojb.FetchaQuery.list(FetchaQuery.java:45) at com.fetchaflick.videotest.movie.BaseMovieFinder.findPageBy(BaseMovieFinder.java:62) at com.fetchaflick.videotest.movie.BaseMovieFinder.findPageByActor(BaseMovieFinder.java:45) at com.fetchaflick.videotest.movie.MovieFinderTest.testFindByActor(MovieFinderTest.java:100) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) <class name="Movie" table="PRODUCT"> <component name="component" class="com.fetchaflick.videotest.movie.Cast"> <list name="list" table="MOVIE_CAST" cascade="all"> <jcs-cache usage="read-write"/> <key column="MOVIE_ID"/> <index column="POS"/> <element type="string" column="NAME"/> </list> </component> </class> Original thread on the forum http://sourceforge.net/forum/forum.php?thread_id=889001&forum_id=128638 I put this in JIRA a while ago, but I guess it lost it (and my account)? --------------------------------------------------------------------- JIRA INFORMATION: This message is automatically generated by JIRA. If you think it was sent incorrectly contact one of the administrators: http://opensource.atlassian.com/projects/hibernate/secure/Administrators.jspa If you want more information on JIRA, or have a bug to report see: http://www.atlassian.com/software/jira |
From: <leg...@at...> - 2003-08-02 11:14:15
|
Message: The following issue has been closed. Resolver: Max Rydahl Andersen Date: Sat, 2 Aug 2003 6:12 AM Is fixed --------------------------------------------------------------------- View the issue: http://opensource.atlassian.com/projects/hibernate/secure/ViewIssue.jspa?key=HB-190 Here is an overview of the issue: --------------------------------------------------------------------- Key: HB-190 Summary: codegenerator creates SortedMap when it should create Map Type: Bug Status: Closed Priority: Major Resolution: DUPLICATE Project: Hibernate2 Components: toolset Versions: 2.0 final Assignee: Max Rydahl Andersen Reporter: Will Glass-Husain Created: Sun, 13 Jul 2003 9:30 PM Updated: Sat, 2 Aug 2003 6:12 AM Environment: Win XP/JDK 1.3.1 Description: The code generator used a SortedMap to represent the following composite element. <class name="com.wgh.om.Rent" table="rent"> <meta attribute="generated-class">com.wgh.om.base.Rent</meta> <id name="rent_id" type="long" unsaved-value="null"> <generator class="identity"/> </id> <map name="amenities"> <key column="rent_id" /> <index column="name" type="string" /> <composite-element class="com.wgh.om.RentAmenity"> <meta attribute="generated-class">com.wgh.om.base.RentAmenity</meta> <property name="name" type="string" not-null="true"/> <property name="category" type="int" /> </composite-element> </map> </class> When I saved the class with this code, I received a PropertyAccessException from cglib. (with the optimizer turned off). hs = HibernateWrapper.getNewSession(ctx); o = new Rent(); o.setAmenities(new TreeMap()); hs.close(); hs = HibernateWrapper.getNewSession(ctx); hs.saveOrUpdate(o); hs.flush(); hs.connection().commit(); hs.close(); 2003-07-13 19:29:04 DEBUG java.lang.ClassCastException: net.sf.hibernate.collection.Map at com.novogradac.valuation.om.RentMetaClass3.setPropertyValues(<generated>) at net.sf.hibernate.persister.AbstractEntityPersister.setPropertyValues(AbstractEntityPersister.java:158) at net.sf.hibernate.impl.SessionImpl.doSave(SessionImpl.java:724) at net.sf.hibernate.impl.SessionImpl.save(SessionImpl.java:620) at net.sf.hibernate.impl.SessionImpl.saveOrUpdate(SessionImpl.java:1214) The solution was to either (A) add sort="natural" to the map hbm.xml, or to change the generated code to use Map instead of SortedMap. Recommendation-- have the codegenerator only use SortedMaps when the sorted attribute is present in the hbm.xml. --------------------------------------------------------------------- JIRA INFORMATION: This message is automatically generated by JIRA. If you think it was sent incorrectly contact one of the administrators: http://opensource.atlassian.com/projects/hibernate/secure/Administrators.jspa If you want more information on JIRA, or have a bug to report see: http://www.atlassian.com/software/jira |
From: <leg...@at...> - 2003-08-02 11:12:16
|
Message: The following issue has been closed. Resolver: Max Rydahl Andersen Date: Sat, 2 Aug 2003 6:11 AM Seems to already be fixed in the current release ? --------------------------------------------------------------------- View the issue: http://opensource.atlassian.com/projects/hibernate/secure/ViewIssue.jspa?key=HB-8 Here is an overview of the issue: --------------------------------------------------------------------- Key: HB-8 Summary: FinderRenderer generates invalid HQL Type: Bug Status: Closed Priority: Minor Resolution: CANNOT REPRODUCE Project: Hibernate2 Components: toolset Versions: 2.0rc2 Assignee: Max Rydahl Andersen Reporter: Tyler Burd Created: Thu, 1 May 2003 1:41 AM Updated: Sat, 2 Aug 2003 6:11 AM Environment: jdk1.4_02, W2k Description: Finder methods generated by the FinderRenderer use the capitalized class name as the identifier in the from clause of the finder HQL. This results in queries like the following: "from User in class com.whatever.User where User.lastName=?" This causes an 'invalid token' error when the finder is executed. The identifier should be all lowercase. This would generate legal queries like the following: "from user in class com.whatever.User where user.lastName=?" Offending lines: classMapping.getName() on lines 142 and 163 of FinderRenderer.java should be classMapping.getName().toLowerCase(). --------------------------------------------------------------------- JIRA INFORMATION: This message is automatically generated by JIRA. If you think it was sent incorrectly contact one of the administrators: http://opensource.atlassian.com/projects/hibernate/secure/Administrators.jspa If you want more information on JIRA, or have a bug to report see: http://www.atlassian.com/software/jira |
From: <leg...@at...> - 2003-08-02 11:07:15
|
Message: The following issue has been closed. Resolver: Max Rydahl Andersen Date: Sat, 2 Aug 2003 6:06 AM hbm2java know only generates isX() for primitive boolean types. Old behavior of also doing it for Boolean types is removed - if requested it can be made optional, but as in the javabean spec it is only explicitly allowed/specified for primitive boolean types - not Boolean. --------------------------------------------------------------------- View the issue: http://opensource.atlassian.com/projects/hibernate/secure/ViewIssue.jspa?key=HB-220 Here is an overview of the issue: --------------------------------------------------------------------- Key: HB-220 Summary: hbm2java generates wrong getter for java.lang.Boolean Type: Bug Status: Closed Priority: Minor Resolution: FIXED Project: Hibernate2 Components: toolset Fix Fors: 2.1 Versions: 2.0.2 Assignee: Max Rydahl Andersen Reporter: Colin Evans Created: Tue, 29 Jul 2003 4:32 PM Updated: Sat, 2 Aug 2003 6:06 AM Description: The hbm2java BasicRenderer generates an "is" getter method for fields of type java.lang.Boolean. It should only do this for primitive fields of type boolean, and this breaks some other bean-based frameworks (such as the JSTL EL tags). --------------------------------------------------------------------- JIRA INFORMATION: This message is automatically generated by JIRA. If you think it was sent incorrectly contact one of the administrators: http://opensource.atlassian.com/projects/hibernate/secure/Administrators.jspa If you want more information on JIRA, or have a bug to report see: http://www.atlassian.com/software/jira |
From: <leg...@at...> - 2003-08-02 08:53:15
|
Message: The following issue has been closed. Resolver: Gavin King Date: Sat, 2 Aug 2003 3:52 AM Closing this, because the user didn't explain how the existing functionality is insufficient. --------------------------------------------------------------------- View the issue: http://opensource.atlassian.com/projects/hibernate/secure/ViewIssue.jspa?key=HB-156 Here is an overview of the issue: --------------------------------------------------------------------- Key: HB-156 Summary: Qualified one-to-many Type: New Feature Status: Closed Priority: Minor Resolution: DUPLICATE Project: Hibernate2 Versions: 2.0.1 Assignee: Reporter: Christian Bauer Created: Tue, 8 Jul 2003 3:36 PM Updated: Sat, 2 Aug 2003 3:52 AM Description: Ability to add static criteria to what would otherwise be a one-to-many relationship, to make it into a one-to-one relationship. Example: Account has one-to-many relationship to Address by way of address.account_id foreign key. However, there is only one "primary" address for a given account, indicated in the datamodel by address.is_primary = 'Y' for exactly one row for any given Account. Enhancement would let me create a property "primaryAddress" on Account that is mapped like a one-to-many except that it also includes something like "...AND primary = true". This allows me to obtain an Account object and call getPrimaryAddress and have that SQL query the address table "WHERE account_id = ? AND is_primary = 'Y'". --------------------------------------------------------------------- JIRA INFORMATION: This message is automatically generated by JIRA. If you think it was sent incorrectly contact one of the administrators: http://opensource.atlassian.com/projects/hibernate/secure/Administrators.jspa If you want more information on JIRA, or have a bug to report see: http://www.atlassian.com/software/jira |