Uploaded image for project: 'Tajo (Retired)'
  1. Tajo (Retired)
  2. TAJO-1972

Invalid sort order with NULLS FIRST|LAST

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Critical
    • Resolution: Fixed
    • None
    • 0.12.0, 0.11.1
    • None
    • None

    Description

      Currently, the order of nulls is affected by the sort order (asc and desc), but should not. Here is the example of pgsql's behaviour.

      postgres=# select * from test;
       id | name  
      ----+-------
        0 | test1
        1 | 
          | test2
      (3 rows)
      postgres=# select * from test order by id  asc nulls first;
       id | name  
      ----+-------
          | test2
        0 | test1
        1 | 
      (3 rows)
      
      postgres=# select * from test order by id  desc nulls first;
       id | name  
      ----+-------
          | test2
        1 | 
        0 | test1
      (3 rows)
      

      Attachments

        Activity

          People

            jihoonson Jihoon Son
            jihoonson Jihoon Son
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: