Skip to content
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

Only cast LONG32 to text on PG to avoid type comparison related issues #9335

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

beikov
Copy link
Contributor

@beikov beikov commented Nov 27, 2024


By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license
and can be relicensed under the terms of the LGPL v2.1 license in the future at the maintainers' discretion.
For more information on licensing, please check here.


@hibernate-github-bot
Copy link

hibernate-github-bot bot commented Nov 27, 2024

Thanks for your pull request!

This pull request does not follow the contribution rules. Could you have a look?

❌ All commit messages should start with a JIRA issue key matching pattern HHH-\d+
    ↳ Offending commits: [9bed471, c7f7602]

› This message was automatically generated.

@gavinking
Copy link
Member

@beikov Why are you proposing to do this?

@gavinking
Copy link
Member

Remember that we have defined LONG32VARCHAR to mean:

In principle, the type must accommodate strings of length 2147483647, though this is not an absolutely hard requirement, since such large strings do not occur in practice.

But PostgreSQL looks like it has the following upper limit for varchar:

hreact=# create table V(V varchar(2147483647));
ERROR:  length for type varchar cannot exceed 10485760
LINE 1: create table V(V varchar(2147483647));
                         ^

which is about two orders of magnitude too small.

@beikov
Copy link
Contributor Author

beikov commented Nov 28, 2024

@beikov beikov changed the title Switch from the text DDL type to varchar to avoid type related issues Only cast LONG32 to text on PG to avoid type comparison related issues Nov 28, 2024
@beikov
Copy link
Contributor Author

beikov commented Nov 28, 2024

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants