算术比较
适用于 ✅ 开源版 ✅ 专业版 ✅ 企业版
一些算术比较可以重新组织,使得单列表达式位于等式的一侧,从而更好地利用索引。虽然基于函数的索引可以帮助解决这个问题,但通常最好依赖更常用的普通索引。
使用 Settings.transformPatternsArithmeticComparisons
,可以实现以下转换
-- With Settings.transformPatternsArithmeticComparisons active, this: SELECT * FROM tab WHERE c + 1 = 3; -- ... is transformed into the equivalent expression: SELECT * FROM tab WHERE c = 3 - 1;
反馈
您对此页面有任何反馈吗? 我们很乐意听取您的意见!