Commit Graph

124 Commits

Author SHA1 Message Date
Yoann Rodière 495bd51caa HHH-14921 Always use SqlStringGenerationContext for generation of SQL strings involving table/sequence names 2021-12-07 08:25:50 +01:00
Christian Beikov cbcec73d4f * Handle quoted identifiers in HQL and the Ordering parser
* Switch from the "expression" to "expressionOrPredicate" rule in the HQL grammar where it makes sense as required by some HQL tests
* Cleanup parser rule ordering to allow more keywords in the identifier rule
* Implement literal support for Ordering parser
* Add special AvgFunction as needed by H2, HSQL, DB2, SQL Server and Sybase that casts arguments to double if necessary
* Fix wrong deduplication of order by fragments in case a plural attribute is fetched multiple times
* Implement support for de-referencing any-valued mappings in HQL
* Avoid unnecessary entity subtypes in polymorphic splitted queries if a base type also matches the requested type
* Implement pagination support for polymorphic splitted queries
* Cleanup path part resolving by removing lots of duplicate code
* Aligh HQL parsing expectations to the expected behavior of 5.x
* Add method to `JavaType` that allows determining if a type is can be widened to another which is used for arithmetic type resolving
* Implement validations for fetch owner checking
* Fix issues with the id table creation due to lacking column lengths in the column DDL type
* Fix issues and add some optimizations related to multi-table delete handling
* Add the notion of a special "implicit" alias to avoid generating a unique alias for unaliased or implicit HQL joins
* Properly implement multiple bag fetch validation
* Make sure filter predicates are applied for all plural attribute joins
* Fix some issues with undecidable parameter type inference
* Fix some issues with negated SQM predicates not being converted to the proper SQL AST predicates
* Fix issues with qualifying DML target referencing columns
* Fix `is null` semantics for tuples referring to embeddable types
* Capture necessary details from JdbcValuesMetadata in the cached data to avoid executing a query on cache hit when types should be inferred
* Get rid of special CollectionPropertyNames and writeup a migration guide section for the replacements
2021-11-25 08:51:51 +01:00
Steve Ebersole 0925e48ebf more user-guide basic-type chapter work;
renamed `JavaTypeDescriptorRegistry` to `JavaTypeRegistry`;
renamed `JdbcTypeDescriptorRegistry` to `JdbcTypeRegistry`
2021-10-25 13:55:53 -05:00
bb7133 5bd27eb853 HHH-14576 : Introduce the dialect for TiDB 2021-10-20 16:19:22 +02:00
Christian Beikov 98de63d0a1 Handle keywords initialization for dialects through DialectResolutionInfo and un-deprecate Dialect#getKeywords 2021-10-20 15:02:48 +02:00
Christian Beikov a4e406a54e * Add SqlTypes as analogy to java.sql.Types containing constants for Hibernate specified types
* Add FormatMapper for a pluggable JSON serialization and deserialization strategy
* Add native UUID type support for H2, Cockroach, PostgreSQL
* Add native INET type support for Cockroach, PostgreSQL
* Add native JSON type support for MySQL, Cockroach, PostgreSQL
* Add native INTERVAL SECOND type support for H2, Cockroach, PostgreSQL
* Add fallback JdbcTypes for new SqlTypes
* Register column types for new SqlTypes
* Add support for BasicTypeReference in TypedParameterValue
* Fix a lot of method signatures with respect to type parameter issues
* Fix CustomType, UserType and EnhancedUserType with respect to type parameters
* Get rid of StringRepresentableType and some other unused deprecated methods
2021-10-19 16:33:36 +02:00
Steve Ebersole 686d8fcbf1 HHH-14870 - Rename {Xyz}TypeDescriptor as {Xyz}Type
* `JavaTypeDescriptor` -> `JavaType`
* `JdbcTypeDescriptor` -> `JdbcType`
2021-10-11 13:13:13 -05:00
Steve Ebersole 3a0065eea4 HHH-14870 - Rename {Xyz}TypeDescriptor as {Xyz}Type
* `JavaTypeDescriptor` -> `JavaType`
* `JdbcTypeDescriptor` -> `JdbcType`
2021-10-11 13:11:32 -05:00
Christian Beikov 548df627e6 Implement global configuration and sketch out annotations for time zone storage configuration. Move type tests and add skips for some tests running into H2 bugs. Also, fix some jdbc type assertion tests 2021-10-11 16:11:46 +02:00
Christian Beikov 597f4bdf6a Get rid of JdbcTypeDescriptor remapping 2021-10-11 16:11:46 +02:00
Christian Beikov 710ebe57b0 Get rid of using specialized BasicType implementations and references to those and instead use a BasicTypeReference that is lazily resolved 2021-10-07 08:15:53 +02:00
Christian Beikov 1cb6ff8916 Cleanup naming of JavaTypeDescriptor and JdbcTypeDescriptor implementations. Get rid of PrimitiveType, IdentifierType, DiscriminatorType and AllowableTemporalParameterType 2021-10-07 08:15:53 +02:00
Christian Beikov 40ccad1db2 Get rid of deprecated dialect methods, JoinFragment, LegacyLimitHandler, LegacySequenceSupport, CaseFragment, SelectFragment etc. 2021-10-05 15:18:38 +02:00
Christian Beikov f416b728a9 Get rid of RowSelection, QueryParameters and related deprecated functionality 2021-10-05 15:18:38 +02:00
Christian Beikov c5baae7e11 Improve SQL rendering performance by avoiding intermediate String objects 2021-10-05 15:18:38 +02:00
Christian Beikov d8b984ed7f Fix some column type definitions in dialects regarding their maximum capacities. Allow the dialect to resolve the length based on type code, type name, precision, scale and display size. Fix some dialect related issues with tests. Fix untyped null parameter binding issues 2021-09-30 13:52:31 +02:00
Christian Beikov 05f643f208 Move some more jpa.test subpackages to orm.test 2021-09-30 13:52:31 +02:00
Steve Ebersole 089a3f86ae HHH-14837 - Move to Jakarta EE
preliminary transformation;
only `javax.persistence.*` settings supported atm
2021-09-27 08:21:27 -05:00
Andrea Boriero 573d146046 Removed Dialect#areStringComparisonsCaseInsensitive() method 2021-09-25 11:52:03 +02:00
Christian Beikov 77c1370e45 HHH-14642, HHH-13717 Various JPA Criteria related fixes
* Get rid of unnecessary whitespace and optional keywords in generated SQL
* Handle some type inference related issues with some databases requiring to render casted parameters in some situations
* Ensure SQM model is fully serializable
* Ensure JPA Criteria throws expected exceptions
* Make sure JPA Criteria implementations work properly
* Move jpa.test.callback and jpa.test.criteria packages
* Improve the reuse of SqmPath instances
* Get rid of many raw-types related warnings
* Make Predicate extend Expression and handle SQL rendering/emulation
* Support fetching SqmTuple as array
* Implement treat operator support
2021-09-09 16:39:31 +02:00
Andrea Boriero 94a258c8d7 Fix wrong creation of inner join 2021-07-08 14:09:46 +02:00
Andrea Boriero 241300c0c1 Fix wrong creation of inner join 2021-07-08 14:09:46 +02:00
Andrea Boriero 8895347867 Fix null dicriminator unable to cast MarkerObject to ... 2021-07-08 11:48:54 +02:00
Christian Beikov 6447ca9b26 HHH-14693, HHH-10668 Move non-supported dialects to the hibernate-community-dialects artifact and add the SQLite dialect originally contributed by Vlad Mihalcea which was adapted for Hibernate 6. Also add HSQLDB, MySQL and Sybase ASE configurations and a CI job config 2021-07-06 10:14:20 +02:00