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

   ### Describe the bug
   
   When list is nested, containing a non-List list-like type, then this 
assertion doesn't hold true
   
   ```rust
   let udf = array_element_udf();
   let udf_type = udf.inner().return_type(&[list_type, index_type])?;
   
   let simplified = Expr::ScalarFunction(expr::ScalarFunction {
           func: udf,
           args: args,
       });
   
   let expr_type = SimplifyInfo::get_data_type(&info, &simplified)?;
   
   assert_eq!(udf_type, expr_type);
   ```
   
   ```
   assertion `left == right` failed
     left: List(Field { name: "element", data_type: Binary, nullable: true, 
dict_id: 0, dict_is_ordered: false, metadata: {} })
    right: FixedSizeList(Field { name: "element", data_type: Binary, nullable: 
true, dict_id: 0, dict_is_ordered: false, metadata: {} }, 1)
   ```
   
   ### To Reproduce
   
   _No response_
   
   ### Expected behavior
   
   For a scalar function call, the `SimplifyInfo::get_data_type` and 
`ExprSchemable::get_type` should return the same type the scalar would return.
   
   ### 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: github-unsubscr...@datafusion.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: github-unsubscr...@datafusion.apache.org
For additional commands, e-mail: github-h...@datafusion.apache.org

Reply via email to