Fix more DB reserved words used by tests

Description

Continuation of HHH-10273.

Activity

Show:

Former userNovember 24, 2015 at 10:18 PM

TestFkUpdating use "Role", which is a keyword on Sybase.

Fixed in master and 5.0 branches.

Former userNovember 24, 2015 at 9:59 PM

EncapsulatedCompositeAttributeResultSetProcessorTest#testNestedCompositeElementCollectionProcessing has a property "date". I've mapped the column name as "`date`".

Fixed in master and 5.0 branches.

Former userNovember 23, 2015 at 7:51 PM

org.hibernate.test.map.MapIndexFormulaTest fails because it uses a column "`password`", and a custom query:

{{ select
lower(u.name) as {u.name}, lower(u."password") as {u.password},
lower(s.userName) as {s.key}, lower(s.name) as {s.index}, s.id as {s.element},
{s.element.*}
from users u}}

The back-tics used for quotes in the column mapping work for creating tables, but for custom native queries, the quotes need to be appropriate to the dialect. Using double-quotes in the custom query does not work. The quotes used in the custom query need to be correct for the dialect. MySQL requires back-tics; other dialects (e.g., H2) require double-quotes.

I've changed the column mapping to "pw", which is not a reserved word so does not need quotes.

Fixed in master and 5.0 branches.

Former userNovember 21, 2015 at 7:04 AM

org.hibernate.test.converter.elementCollection.CollectionElementConversionTest.testElementCollectionConversion
uses a collection attribute "set", which is a reserved word for MySQL 5.5.

Fixed in master and 5.0 branches.

Former userNovember 19, 2015 at 4:54 AM

JavassistInstrumentationTest#testEagerFetchLazyToOne uses an attribute, "number", which is a reserved word for Oracle.

Fixed in 5.0 only; tests were deleted from master by HHH-10280.

Fixed

Details

Assignee

Reporter

Components

Fix versions

Priority

Created November 18, 2015 at 1:57 AM
Updated December 3, 2015 at 12:36 AM
Resolved December 3, 2015 at 12:36 AM

Flag notifications