[FLINK-40355][table] Add new MAP_CONTAINS_KEY function - #28970
Open
VasShabu wants to merge 2 commits into
Open
Conversation
Collaborator
VasShabu
force-pushed
the
mapContainsKeyImplementation
branch
from
August 14, 2026 10:59
b7b48ba to
fb849a3
Compare
davidradl
reviewed
Aug 14, 2026
| try { | ||
| return (boolean) equalityHandle.invoke(key, needle); | ||
| } catch (Throwable t) { | ||
| throw new FlinkRuntimeException(t); |
Contributor
There was a problem hiding this comment.
In the past we have not wanted to issue errors in SQL as it would end the job. I suggest we return false and log in this error case. In the error case they are not equal.
davidradl
reviewed
Aug 14, 2026
| description: | | ||
| Returns TRUE if the given key exists in the map, FALSE otherwise. Returns NULL if the map is | ||
| NULL. A NULL key matches a NULL key in the map. The given key is cast implicitly to the map's | ||
| key type where Flink's implicit casting rules allow it; otherwise the call fails validation. |
Contributor
There was a problem hiding this comment.
when we say fails validation - I assume we should return false as per my other comment
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.
Generated-by: Claude Opus 5