andygrove opened a new issue, #3644: URL: https://github.com/apache/arrow-datafusion/issues/3644
**Describe the bug** Postgres: ``` postgres=# create table test (a decimal(10,2), b decimal(10,2)); CREATE TABLE postgres=# select * from test;l a | b ---+--- (0 rows) postgres=# insert into test values (1,2); INSERT 0 1 postgres=# select * from test; a | b ------+------ 1.00 | 2.00 (1 row) postgres=# select * from test where a != b and case when b > a then a/b else null end >= case when a > b then a/b else null end; a | b ---+--- (0 rows) ``` DataFusion: ``` DataFusion CLI v12.0.0 ❯ create external table test (a decimal(10,2), b decimal(10,2)) stored as csv location 'test.csv'; 0 rows in set. Query took 0.001 seconds. ❯ select * from test where a != b and case when b > a then a/b else null end >= case when a > b then a/b else null end; Internal("The type of Boolean AND Decimal128(10, 2) of binary physical should be same") ``` **To Reproduce** See above **Expected behavior** Should work **Additional context** None -- 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...@arrow.apache.org.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org