From: <leg...@at...> - 2003-05-29 09:58:52
|
Message: A new issue has been created in JIRA. --------------------------------------------------------------------- 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: Invalid sql alias computation for fields with formulas... Type: Bug Status: Unassigned Priority: Minor Project: Hibernate2 Components: core Versions: 2.0rc2 Assignee: Reporter: Fabio Parise Created: Thu, 29 May 2003 4:58 AM Updated: Thu, 29 May 2003 4:58 AM 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/Administrators.jspa If you want more information on JIRA, or have a bug to report see: http://www.atlassian.com/software/jira |