gpt4 book ai didi

sql - Oracle中降序排列为什么先返回NULL值?

转载 作者:搜寻专家 更新时间:2023-10-30 21:40:29 24 4
gpt4 key购买 nike

当没有指定NULL排序时,那么对NULL值的处理是:

  • 如果排序是 ASC,则 NULL 值排在最后
  • 如果排序是 DESC,则 NULL 值排在第一位

为什么会这样?

enter image description here

最佳答案

Oracle 文档中是这样写的:

If the null ordering is not specified then the handling of the null values is:NULLS LAST if the sort is ASCNULLS FIRST if the sort is DESC

Here是的。

关于sql - Oracle中降序排列为什么先返回NULL值?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/34613211/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com