Add expected errors for postgres 18#1298
Open
albertZhangTJ wants to merge 2 commits intosqlancer:mainfrom
Open
Add expected errors for postgres 18#1298albertZhangTJ wants to merge 2 commits intosqlancer:mainfrom
albertZhangTJ wants to merge 2 commits intosqlancer:mainfrom
Conversation
mrigger
reviewed
Mar 3, 2026
| public static List<String> getCommonExpressionErrors() { | ||
| ArrayList<String> errors = new ArrayList<>(); | ||
|
|
||
| errors.add("for encoding \"SQL_ASCII\" does not exist"); |
Contributor
There was a problem hiding this comment.
Hmm, why does this happen? Is this something that we should avoid generating instead?
Collaborator
Author
There was a problem hiding this comment.
I err towards adding this as expected error.
The root cause is if the database was created without specifying UTF8 encoding, then specifying COLLATE later will be invalid. e.g.
CREATE DATABASE database7 TEMPLATE template0;
CREATE UNLOGGED TABLE t3(c0 TEXT COLLATE "pg_c_utf8" UNIQUE) INHERITS(t2, t1);
The other fix option would be enforcing UTF8 encoding in PostgresProvider instead of making it randomized, but I feel like it will lead to less diverse behaviors.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Add expected errors related to SQL_ASCII encoding in PG18; Add error message related to WAL enforcement on partitioned table