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

Allow metadata fields in PPL query #2789

Merged
merged 1 commit into from
Jan 10, 2025

Conversation

LantaoJin
Copy link
Member

Description

OpenSearch reserved fields (_id, _index, _sort, _score, _max_score) are not allowed to be used in PPL clauses because the field format starting with underscore _ is not allowed.

  • This ticket adds specific identifiers to the language, and opens up support for OpenSearch reserved identifiers.
  • As an aside, identifiers with double underscore at the start (such as __myCoolField) is acceptable as an identifier.

#1456 had fixed the same problem for SQL query, but the issue still existed in PPL.

Issues Resolved

Resolves #2788

Check List

  • New functionality includes testing.
    • All tests pass, including unit test, integration test and doctest
  • New functionality has been documented.
    • New functionality has javadoc added
    • New functionality has user manual doc added
  • Commits are signed per the DCO using --signoff

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.

Signed-off-by: Lantao Jin <ltjin@amazon.com>
@LantaoJin LantaoJin force-pushed the pr/bugfix_issue_2788 branch from 446622c to 9c8ba3d Compare July 9, 2024 06:46
Copy link
Collaborator

@dai-chen dai-chen left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the fix!

@LantaoJin
Copy link
Member Author

Gently ping @penghuo @vamsi-amazon @YANG-DB

@opensearch-trigger-bot
Copy link
Contributor

This PR is stalled because it has been open for 30 days with no activity.

@LantaoJin LantaoJin merged commit e415325 into opensearch-project:main Jan 10, 2025
14 checks passed
opensearch-trigger-bot bot pushed a commit that referenced this pull request Jan 10, 2025
Signed-off-by: Lantao Jin <ltjin@amazon.com>
(cherry picked from commit e415325)
Signed-off-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[BUG] _id is not available in PPL where condition
3 participants