[Hibernate-JIRA] Created: (ANN-823) Unit tests fail because Insert into ... values(upper(?)) fails on DB2
by Gail Badner (JIRA)
Unit tests fail because Insert into ... values(upper(?)) fails on DB2
---------------------------------------------------------------------
Key: ANN-823
URL: http://opensource.atlassian.com/projects/hibernate/browse/ANN-823
Project: Hibernate Annotations
Issue Type: Bug
Reporter: Gail Badner
The following tests fail with DB2Dialect:
org.hibernate.test.annotations.join.JoinTest.testFetchModeOnSecondaryTable()
org.hibernate.test.annotations.join.JoinTest.testCustomSQL()
due to failure on:
insert into Cat2 (storyPart2, id) values (upper(?), ?)
The following tests fail:
org.hibernate.test.annotations.query.QueryAndSQLTest.testEntitySQLOverriding()
org.hibernate.test.annotations.query.QueryAndSQLTest.testCollectionSQLOverriding()
due to failure on:
INSERT INTO CHAOS(name, nick_name, chaos_size, id) VALUES(upper(?),?,?,?)
The tests pass if upper(?) is changed to upper(? || ''), but this may not work on all dialects.
--
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....
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
14 years, 3 months
[Hibernate-JIRA] Created: (HBX-1161) Schema Export lacks warning signs
by Joachim Durchholz (JIRA)
Schema Export lacks warning signs
---------------------------------
Key: HBX-1161
URL: http://opensource.atlassian.com/projects/hibernate/browse/HBX-1161
Project: Hibernate Tools
Issue Type: Improvement
Components: eclipse
Affects Versions: 3.2.4 Beta1
Environment: Actually, Hibernate Tools 3.3.0.v201002250004M-H277-CR2
Reporter: Joachim Durchholz
Priority: Critical
In the standard Eclipse install, Hibernate Tools have a list of exporters.
One of them is "Schema Export (.ddl)". The standard assumption would be that it's exporting a set of .ddl files (which would have to be manually applied).
What actually happens is that any changes are immediately applied to the database. The worst case would be data loss on a production database. (Hey, this just happened to me. Now I'm going to spend the next two hours validating that nothing relevant actually got changed in the DDL.)
To avoid unexpected database changes, I propose of the following two changes:
1) Modify the Schema Export exporter to create .ddl files by default.
2) Rename "Schema Export" to "Schema Export (MODIFIES DATABASE BY DEFAULT)", and/or change the icon so it's different from that of "Schema Documentation". (Technically, the two are doing similar things, but the consequences are deeply different.)
3) Split "Schema Export" into "Schema Export" (create .ddl files that can be manually applied) and "Direct Database Schema Update" (apply DDL changes directly to the database).
(I'm now off to checking the DDL of the database to see what changes, if any, were applied by Hibernate Tools. Hey, I'm reverse engineering off the production database because the test system is not always up to date.)
--
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....
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
14 years, 3 months
[Hibernate-JIRA] Created: (HHH-4998) org.hibernate.test.hql.ASTParserLoadingTest failure running testStr with Ingres
by Ray Fan (JIRA)
org.hibernate.test.hql.ASTParserLoadingTest failure running testStr with Ingres
--------------------------------------------------------------------------------
Key: HHH-4998
URL: http://opensource.atlassian.com/projects/hibernate/browse/HHH-4998
Project: Hibernate Core
Issue Type: Bug
Components: query-hql, testsuite
Affects Versions: 3.5.0-CR-2
Environment: Hibernate 3.5.0-CR-2, Ingres 9.3.1 (int.lnx/106), IngresDialect
Reporter: Ray Fan
Priority: Minor
Attachments: hql-astparserloadingtest.zip
Assertion failure during testStr in hql ASTParserLoadingTest
{noformat}
<failure message="expected:<...> but was:<... >" type="junit.framework.ComparisonFailure">junit.framework.ComparisonFailure: expected:<...> but was:<... >
at junit.framework.Assert.assertEquals(Assert.java:81)
at junit.framework.Assert.assertEquals(Assert.java:87)
at org.hibernate.test.hql.ASTParserLoadingTest.testStr(ASTParserLoadingTest.java:1593)
</failure>
{noformat}
The generated SQL query
{noformat}
select
(cast(year(current_date) as char)+'-'+cast(month(current_date) as char)+'-'+cast(day(current_date) as char)) as col_0_0_
from
Animal animal0_
{noformat}
The cast to char produces space padded values causing the failure.
--
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....
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
14 years, 3 months