-
Notifications
You must be signed in to change notification settings - Fork 3.6k
HHH-5909 improving alias generation in columns #2666
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Incomplete, found another aliasing issue |
I am not sure why travis fails in so many places (other than assuming very strict assumptions/expectations on other tests. I am using this patch in our environment and it does as expected. |
@SchlauFuchs, I'm seeing the same test failures when I run the tests locally. Have you looked into why this is happening? |
I had only a short look into it and could not fully determine the reason.
Debugging there was quite difficult and I got only two paid days from my
company to investigate a solution. I might help on solving this in a few
days in christmas break on my own, but if you can find time for a root
analysis that would be great
…On Thu, 20 Dec 2018 at 13:22, gbadner ***@***.***> wrote:
@SchlauFuchs <https://github.com/SchlauFuchs>, I'm seeing the same test
failures when I run the tests locally. Have you looked into why this is
happening?
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#2666 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AA6unVYJGTi04HoxLDu5KkEuN7bdaEjNks5u6thQgaJpZM4Y2y0X>
.
|
… for auto-close with JPA_PROXY_COMPLIANCE enabled.
… for auto-close with JPA_PROXY_COMPLIANCE enabled
…nly an identity-based column. Exclude tests failing for SAP HANA and add the supportNoColumnInsert method in Dialect to be used by the Insert class
HHH-13129 : Move and reformat test HHH-13129 : Add more tests
…y with uninitialized ToOne
The first commit was on the safe side, we decided to go the extra mile and that was a mistake as we missed all the consequences. The new issue is about having a shared ReaderCollector: we add the info there for each batch which leads to collecting the elements several times. This reverts commit a19fc84. HHH-13059 : Correct Javadoc
Keep the test and add a @FailureExpected annotation
… detached entities.
…-13042 and HHH-11019.
…erviceRegistryImpl
@SchlauFuchs The Changing the alias generation is risky and the current solution is also "hacky". I think we should close this issue and wait for 6.0 to validate the new SQL rendering implementation. |
… Self Referential Entity with Single_Table Inherited Entities
I agree, I was not aware of the 6.0 change, when I committed the change.
But I am trying to use 5.4 in production and the problem with aliases was
seriously blocking me from using a production-ready version of V5.4 as we
have column names too long for the current alias generation to pass. It
seriously caused lots of SQL errors for having exceeded the alias length
limit. There IS a bug in the calculation of the alias prefix length that I
sorted and it allows me to use Hibernate now.
The fix becomes obsolete when 6.0 becomes GA.
…On Fri, 18 Jan 2019 at 00:14, Vlad Mihalcea ***@***.***> wrote:
@SchlauFuchs <https://github.com/SchlauFuchs> The SellCarTest fails and I
think it's not worth adding this change in 5.x as long as 6.0 changes the
SQL rendering and it does not even use aliases.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#2666 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AA6unXq79fFDwjpuWJQ3Tu1yjiveBOTxks5vEFsygaJpZM4Y2y0X>
.
|
This issue is quite old so it affects all versions of Hibernate, not just 5.4. If the issue is really important for you, you could try to enhance it so that all tests pass. Anyway, modifying the Column alone is not enough. The aliases used during JPQL parsing is not covered by this PR. So, there's more work to be done to fix this propertly. |
Currently, we don't have a way to properly handle enum literals so get back to using parameter binding, which was used before in the "case when" case due to a bug fixed in HHH-13001. Note that this forces the usage of enum literals even at the root of the select clause.
It was removed as part of hibernate#1361 but this PR didn't fix all the issues as there are still cases where we don't deduce the expected type and we need to have a proper cast.
This reverts commit 23153d5.
…Expected Reintroducing CaseLiteralExpression had some issues with databases other than H2 as it tried to cast to binary even if the enum was stored as enumerated. Unfortunately, we cannot really know if the enum is in the end compared to a value stored as a string or a number.
PR is out-of-date. |
Hi,
I am fixing https://hibernate.atlassian.net/browse/HHH-5909, as it causes me some pain.
Enjoy.