Sybase:BETWEEN 与“<=”和“>=”运营商

发布于 2024-12-13 12:48:12 字数 389 浏览 3 评论 0 原文

使用 BETWEEN 与比较运算符在性能方面是否存在根本差异?其中一个 wiki 推荐后者:

3:用 >= 和 <= 运算符替换 BETWEEN,因为 BETWEEN 又会转换为提到的运算符。这样我们就可以减少一步。

http://sybaseblog.com /sybasewiki/index.php?title=What_are_the_basics_of_performance_tuning%3F

干杯, 版本

Is there a fundamental difference in terms of performance with regards to using BETWEEN versus the comparison operators? One of the wikis recommends the latter:

3: Replace the BETWEEN with >= and <= operators because BETWEEN in turn converted to mentioned oprators. So with we can reduce one step.

http://sybaseblog.com/sybasewiki/index.php?title=What_are_the_basics_of_performance_tuning%3F

Cheers,
Ver

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

累赘 2024-12-20 12:48:12

是的。有一个根本的区别。 BETWEEN 需要解释为适当的运算符。这是系统需要采取的额外步骤。

如果您预先使用运算符,则可以节省该步骤......这会加快速度(甚至略有加快)。

Yes. There is a fundamental difference. BETWEEN needs to be interpreted to the appropriate operators. That's an added step for the system to take.

If you use the operators up front, you can save that step...which speeds things up (even marginally).

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文