HHH-7733 NativeSQLQueriesTest failing on Postgres

This commit is contained in:
brmeyer 2012-10-29 14:24:43 -04:00
parent 718dd237f5
commit 0c5ad566b6
2 changed files with 8 additions and 8 deletions

View File

@ -53,7 +53,7 @@
<property name="endDate" column="ENDDATE" insert="false"/> <property name="endDate" column="ENDDATE" insert="false"/>
<property name="regionCode" column="REGIONCODE" update="false"/> <property name="regionCode" column="REGIONCODE" update="false"/>
<property name="salary" type="org.hibernate.test.sql.hand.MonetaryAmountUserType"> <property name="salary" type="org.hibernate.test.sql.hand.MonetaryAmountUserType">
<column name="`VALUE`" sql-type="float"/> <column name="AMOUNT" sql-type="float"/>
<column name="CURRENCY"/> <column name="CURRENCY"/>
</property> </property>
</class> </class>
@ -246,7 +246,7 @@
<return-property name="element.regionCode" column="REGIONCODE"/> <return-property name="element.regionCode" column="REGIONCODE"/>
<return-property name="element.employmentId" column="EMPID"/> <return-property name="element.employmentId" column="EMPID"/>
<return-property name="element.salary"> <return-property name="element.salary">
<return-column name="`VALUE`"/> <return-column name="AMOUNT"/>
<return-column name="CURRENCY"/> <return-column name="CURRENCY"/>
</return-property> </return-property>
</return-join> </return-join>
@ -259,7 +259,7 @@
emp.STARTDATE as xstartDate, emp.STARTDATE as xstartDate,
emp.ENDDATE as endDate, emp.ENDDATE as endDate,
emp.REGIONCODE as regionCode, emp.REGIONCODE as regionCode,
emp.VALUE as VALUE, emp.AMOUNT as AMOUNT,
emp.CURRENCY as CURRENCY emp.CURRENCY as CURRENCY
FROM ORGANIZATION org FROM ORGANIZATION org
LEFT OUTER JOIN EMPLOYMENT emp ON org.ORGID = emp.EMPLOYER LEFT OUTER JOIN EMPLOYMENT emp ON org.ORGID = emp.EMPLOYER
@ -279,7 +279,7 @@
emp.STARTDATE as startDate, emp.STARTDATE as startDate,
emp.ENDDATE as endDate, emp.ENDDATE as endDate,
emp.REGIONCODE as regionCode, emp.REGIONCODE as regionCode,
emp.VALUE as VALUE, emp.AMOUNT as AMOUNT,
emp.CURRENCY as CURRENCY emp.CURRENCY as CURRENCY
FROM ORGANIZATION org FROM ORGANIZATION org
LEFT OUTER JOIN EMPLOYMENT emp ON org.ORGID = emp.EMPLOYER LEFT OUTER JOIN EMPLOYMENT emp ON org.ORGID = emp.EMPLOYER

View File

@ -536,7 +536,7 @@ public class NativeSQLQueriesTest extends BaseCoreFunctionalTestCase {
assertEquals(1, list.size()); assertEquals(1, list.size());
m = (Map) list.get(0); m = (Map) list.get(0);
assertTrue(m.containsKey("EMPID")); assertTrue(m.containsKey("EMPID"));
assertTrue(m.containsKey("VALUE")); assertTrue(m.containsKey("AMOUNT"));
assertTrue(m.containsKey("ENDDATE")); assertTrue(m.containsKey("ENDDATE"));
assertEquals(8, m.size()); assertEquals(8, m.size());
@ -650,7 +650,7 @@ public class NativeSQLQueriesTest extends BaseCoreFunctionalTestCase {
" emp.STARTDATE as startDate," + " emp.STARTDATE as startDate," +
" emp.ENDDATE as endDate," + " emp.ENDDATE as endDate," +
" emp.REGIONCODE as regionCode," + " emp.REGIONCODE as regionCode," +
" emp.VALUE as VALUE," + " emp.AMOUNT as AMOUNT," +
" emp.CURRENCY as CURRENCY" + " emp.CURRENCY as CURRENCY" +
" FROM ORGANIZATION org" + " FROM ORGANIZATION org" +
" LEFT OUTER JOIN EMPLOYMENT emp ON org.ORGID = emp.EMPLOYER"; " LEFT OUTER JOIN EMPLOYMENT emp ON org.ORGID = emp.EMPLOYER";
@ -678,7 +678,7 @@ public class NativeSQLQueriesTest extends BaseCoreFunctionalTestCase {
.addProperty( "element.endDate", "endDate" ) .addProperty( "element.endDate", "endDate" )
.addProperty( "element.regionCode", "regionCode" ) .addProperty( "element.regionCode", "regionCode" )
.addProperty( "element.employmentId", "empId" ) .addProperty( "element.employmentId", "empId" )
.addProperty( "element.salary" ).addColumnAlias( "VALUE" ).addColumnAlias( "CURRENCY" ); .addProperty( "element.salary" ).addColumnAlias( "AMOUNT" ).addColumnAlias( "CURRENCY" );
sqlQuery.list(); sqlQuery.list();
// lets try a totally different approach now and pull back scalars, first with explicit types // lets try a totally different approach now and pull back scalars, first with explicit types
@ -690,7 +690,7 @@ public class NativeSQLQueriesTest extends BaseCoreFunctionalTestCase {
.addScalar( "endDate", TimestampType.INSTANCE ) .addScalar( "endDate", TimestampType.INSTANCE )
.addScalar( "regionCode", StringType.INSTANCE ) .addScalar( "regionCode", StringType.INSTANCE )
.addScalar( "empId", LongType.INSTANCE ) .addScalar( "empId", LongType.INSTANCE )
.addScalar( "VALUE", FloatType.INSTANCE ) .addScalar( "AMOUNT", FloatType.INSTANCE )
.addScalar( "CURRENCY", StringType.INSTANCE ); .addScalar( "CURRENCY", StringType.INSTANCE );