goldmedal opened a new issue, #11434:
URL: https://github.com/apache/datafusion/issues/11434

   ### Is your feature request related to a problem or challenge?
   
   Based on the discussion in 
https://github.com/apache/datafusion/issues/11268#issuecomment-2211125762, we 
will support the MAP literal to create a map value. Referring to the [DuckDB 
syntax](https://duckdb.org/docs/sql/data_types/map.html), we can use syntax 
like:
   
   ```sql
   SELECT MAP {'key1': 10, 'key2': 20, 'key3': 30};
   ```
   
   ### Describe the solution you'd like
   
   After #11361, we now have two functions: `map` and `make_map`. We can use 
`UserDefinedSQLPlanner` to implement the proposed syntax and rewrite it to the 
`map` function. As @jayzhan211 mentioned in 
https://github.com/apache/datafusion/pull/11361#issuecomment-2221710127, we can 
also use `ExprPlanner` to handle the `make_map` function. Since `make_map` is 
less efficient than the `map` function, we should retain only the faster `map` 
scalar function implementation. For more details, see the previous discussions 
and benchmark results in #11361.
   
   ### Describe alternatives you've considered
   
   _No response_
   
   ### Additional context
   
   _No response_


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to