Yulin PEI <ype...@connect.ust.hk> writes: > Let's look at your patch:
> ``` > // node is ('1' COLLATE "C") > // targetType is varbit and it is non-collatable > if (IsA(node, CollateExpr) && type_is_collatable(targetTypeId)) > { > // we will not reach here. That's not the committed patch, though. I realized after posting it that it didn't maintain the same behavior in coerce_type as coerce_to_target_type. But the actually-committed fix does, and as I said, what you're suggesting seems equivalent though a bit messier. regards, tom lane