spark-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Dongjoon Hyun (JIRA)" <j...@apache.org>
Subject [jira] [Resolved] (SPARK-28333) NULLS FIRST for DESC and NULLS LAST for ASC
Date Wed, 31 Jul 2019 17:27:00 GMT

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

Dongjoon Hyun resolved SPARK-28333.
-----------------------------------
    Resolution: Won't Do

Please see the discussion and review comments on the PR.

> NULLS FIRST for DESC and NULLS LAST for ASC
> -------------------------------------------
>
>                 Key: SPARK-28333
>                 URL: https://issues.apache.org/jira/browse/SPARK-28333
>             Project: Spark
>          Issue Type: Sub-task
>          Components: SQL
>    Affects Versions: 3.0.0
>            Reporter: Yuming Wang
>            Priority: Major
>
> {code:sql}
> spark-sql> create or replace temporary view t1 as select * from (values(1), (2), (null),
(3), (null)) as v (val);
> spark-sql> select * from t1 order by val asc;
> NULL
> NULL
> 1
> 2
> 3
> spark-sql> select * from t1 order by val desc;
> 3
> 2
> 1
> NULL
> NULL
> {code}
> {code:sql}
> postgres=# create or replace temporary view t1 as select * from (values(1), (2), (null),
(3), (null)) as v (val);
> CREATE VIEW
> postgres=# select * from t1 order by val asc;
>  val
> -----
>    1
>    2
>    3
> (5 rows)
> postgres=# select * from t1 order by val desc;
>  val
> -----
>    3
>    2
>    1
> (5 rows)
> {code}
> https://www.postgresql.org/docs/11/queries-order.html



--
This message was sent by Atlassian JIRA
(v7.6.14#76016)

---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@spark.apache.org
For additional commands, e-mail: issues-help@spark.apache.org


Mime
View raw message