goldmedal commented on issue #11268:
URL: https://github.com/apache/datafusion/issues/11268#issuecomment-2212299543

   > what is your code for benchmarking?
   > 
   
   Here's my testing code. 
   
https://github.com/goldmedal/datafusion/blob/feature/11268-scalar-funciton-map-v2/datafusion/functions/src/core/map.rs
   
   > Given the code, it seems you clone ColumnValue and push to VecDeque, we 
can avoid the clone and use Vec instead of VecDeque, since we don't need 
`push_front`.
   > 
   
   Sounds great. I will try it.
   
   > 
   > You only take the first element, but shouldn't we process all the kv?
   > 
   > ```rust
   >     make_map_batch(&[key[0].clone(), value[0].clone()])
   > ```
   
   oops. It's an unfinished work. I forgot it. Yes, you're right. Thanks.
   We should take all. The key and value vec would be
   ```
   [datafusion/functions/src/core/map.rs:97:5] key.clone() = [
       StringArray
       [
         "key_265622076",
       ],
       StringArray
       [
         "key_-178310949",
       ],
       StringArray
       [
         "key_-2138625601",
       ],
       StringArray
       [
         "key_-814401492",
       ],
   ]
   ```
   I think I need to contact them to be one key array and one value array.
   


-- 
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