SQL Server equivalent to Oracle's NULLS FIRST?

前端 未结 8 578
心在旅途
心在旅途 2020-12-08 00:50

So Oracle has NULLS FIRST, which I can use to have null values sorted at the top followed by my column value in descending order:

ORDER BY date_sent NULLS FI         


        
8条回答
  •  野趣味
    野趣味 (楼主)
    2020-12-08 00:59

    ORDER BY
      COALESCE(POSTING_DATE,'1900-01-01 00:00:00.000')
     ,OTHER_FIELDS
    

提交回复
热议问题