acking-you commented on PR #19420: URL: https://github.com/apache/datafusion/pull/19420#issuecomment-3715036307
> I encountered a short-circuit evaluation issue with BinaryExpr when using DataFusion. The operator on the right side may be a function, which should only be called after the left-side condition is satisfied; otherwise, executing the function may result in errors (such as illegal content exceptions). Sorry for the late reply—I'm really curious to know what this specific case is about? For example, I didn't quite understand the examples you gave below. and why does setting a larger value fix the issue? ```sql create table tmp_xml ( id int ,c1 string) stored as parquet ; insert overwrite table tmp_xml values (1,'a'),(5,'<'),(5,'<'),(5,'<'),(5,'<'),(5,'<'),(5,'<'),(2,'<data><k1>v1</k1></data>'),(3,'<daa>'),(4,'>'),(5,'<'),(5,'<'),(5,'<'),(5,'<'),(5,'<'),(5,'<'); select * , case when id=2 and xpath_string(c1,'/data/k1')= 'v1' then 'xml' else 'no_xml' end as extracted_value from tmp_xml; ``` -- 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]
