opensearch-project / opensearch-project/sql
[FEATURE] Support field aliases that target text multi-fields in SQL/PPL
Nobody has claimed this yet.
- Dominant language
- Java
- Stars
- 176
- Forks
- 229
- Avg merge
- 2d 21h
- Merged PRs (30d)
- 43
Description
Problem
A field alias whose path points to a text multi-field (e.g. alias title_raw → title.raw, where title is text with fields.raw as keyword) cannot be resolved by SQL/PPL. #5535/#5536 handled the resulting NullPointerException by returning FIELD_NOT_FOUND, but the alias pattern itself is still unsupported.
Request
Resolve aliases whose target is a text multi-field, so SELECT title_raw FROM index returns the sub-field value — consistent with how OpenSearch core resolves these aliases in native search.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by tracing the SQL/PPL field-alias resolution path and review the handling introduced by #5535/#5536 for text multi-fields. Compare it with OpenSearch core's native alias resolution, then verify that an alias such as title_raw targeting title.raw returns the sub-field value in SELECT title_raw FROM index without FIELD_NOT_FOUND.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java, sql
- Domain
- databases
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 48/100