You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@calcite.apache.org by "Julian Hyde (Jira)" <ji...@apache.org> on 2019/09/25 04:04:00 UTC

[jira] [Resolved] (CALCITE-3370) Emulate NULL direction for MSSQL

     [ https://issues.apache.org/jira/browse/CALCITE-3370?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Julian Hyde resolved CALCITE-3370.
----------------------------------
    Fix Version/s: 1.22.0
       Resolution: Fixed

Fixed in [0c8cbacd|https://github.com/apache/calcite/commit/0c8cbacd0f30b5df15b7cb93c0ab2be5d0324372]; thanks for the PR, [~jswett]!

> Emulate NULL direction for MSSQL
> --------------------------------
>
>                 Key: CALCITE-3370
>                 URL: https://issues.apache.org/jira/browse/CALCITE-3370
>             Project: Calcite
>          Issue Type: Task
>            Reporter: Justin Swett
>            Priority: Minor
>              Labels: pull-request-available
>             Fix For: 1.22.0
>
>          Time Spent: 10m
>  Remaining Estimate: 0h
>
> MSSQL cannot handle NULLS LAST/FIRST and should emulate the NULLS LAST/FIRST in order by, i.e.
> --for nulls last
> select [column] from [table]  ORDER BY CASE WHEN [column] IS NULL THEN 1 ELSE 0 END, [column]"
> --for nulls first
> select [column] from [table]  ORDER BY CASE WHEN [column] IS NULL THEN 0 ELSE 1 END, [column]"



--
This message was sent by Atlassian Jira
(v8.3.4#803005)