[Feature Request]: calcite SQL support map with a nonnull value
- Dominant language
- Java
- Stars
- 8.7k
- Forks
- 4.7k
- Avg merge
- 2d 5h
- Merged PRs (30d)
- 204
Description
### What would you like to happen?
we can only use `map not null` in beam sql, the value of map can be null, however, when I debug a row of sql output, its avro schema is
```java
"type": {
"type": "map",
"values": [
"null",
"boolean"
]
}
```
### Issue Priority
Priority: 3 (nice-to-have improvement)
### Issue Components
- [ ] Component: Python SDK
- [X] Component: Java SDK
- [ ] Component: Go SDK
- [ ] Component: Typescript SDK
- [ ] Component: IO connector
- [ ] Component: Beam examples
- [ ] Component: Beam playground
- [ ] Component: Beam katas
- [ ] Component: Website
- [ ] Component: Spark Runner
- [ ] Component: Flink Runner
- [ ] Component: Samza Runner
- [ ] Component: Twister2 Runner
- [ ] Component: Hazelcast Jet Runner
- [ ] Component: Google Cloud Dataflow Runner
Contributor guide
Research direction
Start by tracing Beam SQL's handling of MAP types into the Avro schema shown in the issue. Check how a non-null value declaration is represented, then verify with a focused Java SDK test that the generated schema preserves that constraint. Done means MAP values are represented as non-null rather than as a nullable union.
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
- 45/100