Fix for Postgres regex and like binary operators (#1928)

This commit is contained in:
Sergey Olontsev 2025-07-17 09:07:28 +01:00 committed by GitHub
parent 650681422a
commit 4d9338638f
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 55 additions and 15 deletions

View file

@ -3486,10 +3486,18 @@ impl<'a> Parser<'a> {
| BinaryOperator::LtEq
| BinaryOperator::Eq
| BinaryOperator::NotEq
| BinaryOperator::PGRegexMatch
| BinaryOperator::PGRegexIMatch
| BinaryOperator::PGRegexNotMatch
| BinaryOperator::PGRegexNotIMatch
| BinaryOperator::PGLikeMatch
| BinaryOperator::PGILikeMatch
| BinaryOperator::PGNotLikeMatch
| BinaryOperator::PGNotILikeMatch
) {
return parser_err!(
format!(
"Expected one of [=, >, <, =>, =<, !=] as comparison operator, found: {op}"
"Expected one of [=, >, <, =>, =<, !=, ~, ~*, !~, !~*, ~~, ~~*, !~~, !~~*] as comparison operator, found: {op}"
),
span.start
);