comphead commented on PR #5452:
URL: 
https://github.com/apache/datafusion-comet/pull/5452#issuecomment-5460581531

   Thanks @sunchao I'm proposing to have this PR as is, as it actually refers 
to support map inside array literal. 
   
   ```
   SELECT try_element_at(element_at(map(1, map(0, 7)), id),
                         id % (id - 2)) FROM t;
   ```
   no array literal, its most likely existing issue, we need to address.
   
   
   ```
   SELECT element_at(
     element_at(array(CAST(NULL AS ARRAY<BIGINT>),
                      array(monotonically_increasing_id(), CAST(NULL AS 
BIGINT))), id),
     id - 1) FROM t;
   ```
   its not array of map
   
   ```
   SELECT array_contains(
     map_values(element_at(map(1, map(1, 'A1' COLLATE UTF8_LCASE)), id)),
     'a1' COLLATE UTF8_LCASE) FROM t;
   ```
   
   this is good, yes
   
   
   ```
   SELECT slice(array(map(1, coalesce(id, 0))), 1, 1) FROM t;
   
   ```
   
   here there reported problem for `slice`
   
   
   I'm totally down we need to fix all of issues above, they just beyond the 
scope of the original issue. what about creating smaller follow up PRs to 
address issues above?


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