You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@calcite.apache.org by "duan xiong (Jira)" <ji...@apache.org> on 2021/10/19 06:22:00 UTC

[jira] [Updated] (CALCITE-4860) Elasticsearch adapter support NULLS FIRST and NULLS LAST in ORDER BY

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

duan xiong updated CALCITE-4860:
--------------------------------
    Description: 
In Elasticsearch Adapter, The SQL:
{code:java}
@Test void integerCat3() {
  CalciteAssert.that()
      .with(newConnectionFactory())
      .query("select cat1 from view order by cat1 nulls first")
      .returns("cat1=a\n" +
          "cat1=b\n" +
          "cat1=null\n");
}
{code}
NULLS FIRST don't handle.

According  [es_missing_values|https://www.elastic.co/guide/en/elasticsearch/reference/current/sort-search-results.html#_missing_values] . We can add another parameter in the script to implement this.

  was:
In Elasticsearch Adapter, The SQL:

 
{code:java}
@Test void integerCat3() {
  CalciteAssert.that()
      .with(newConnectionFactory())
      .query("select cat1 from view order by cat1 nulls first")
      .returns("cat1=a\n" +
          "cat1=b\n" +
          "cat1=null\n");
}
{code}
NULLS FIRST don't handle.

 

According  [es_missing_values|https://www.elastic.co/guide/en/elasticsearch/reference/current/sort-search-results.html#_missing_values] . We can add another parameter in the script to implement this.


> Elasticsearch adapter support NULLS FIRST and NULLS LAST in ORDER BY
> --------------------------------------------------------------------
>
>                 Key: CALCITE-4860
>                 URL: https://issues.apache.org/jira/browse/CALCITE-4860
>             Project: Calcite
>          Issue Type: Bug
>          Components: elasticsearch-adapter
>    Affects Versions: 1.27.0
>            Reporter: duan xiong
>            Priority: Major
>             Fix For: 1.29.0
>
>
> In Elasticsearch Adapter, The SQL:
> {code:java}
> @Test void integerCat3() {
>   CalciteAssert.that()
>       .with(newConnectionFactory())
>       .query("select cat1 from view order by cat1 nulls first")
>       .returns("cat1=a\n" +
>           "cat1=b\n" +
>           "cat1=null\n");
> }
> {code}
> NULLS FIRST don't handle.
> According  [es_missing_values|https://www.elastic.co/guide/en/elasticsearch/reference/current/sort-search-results.html#_missing_values] . We can add another parameter in the script to implement this.



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