Details

    Description

      Feature request for Oracle/DB2 migration compatibility:

      We are using the window function "ROW_NUMBER() OVER()" to generate the row sequence number required for pagination across the pages. For example:

      SELECT ROW_NUMBER() OVER() as RN, COL1, COL2 FROM MYTABLE;
      

      Since there is no expression given in the OVER() clause, DB2 will just assign sequential numbers to the output. The column RN returned from the query will have numbers in perfect order.

      However, MariaDB does not guarantee the numbers in order without an explicit ORDER BY.

      This will require query re-writing in order to migrate.

      Attachments

        Issue Links

          Activity

            (I assume "ROW_NUMBER() ORDER()" had a typo, changed it to be "ROW_NUMBER() OVER()" )

            psergei Sergei Petrunia added a comment - (I assume "ROW_NUMBER() ORDER()" had a typo, changed it to be "ROW_NUMBER() OVER()" )

            Window Functions will now force the result set to use the last ordering that the server used to compute their values. This only happens if there is no specific ORDER BY for the SELECT statement.

            cvicentiu Vicențiu Ciorbaru added a comment - Window Functions will now force the result set to use the last ordering that the server used to compute their values. This only happens if there is no specific ORDER BY for the SELECT statement.

            People

              cvicentiu Vicențiu Ciorbaru
              ccalender Chris Calender (Inactive)
              Votes:
              2 Vote for this issue
              Watchers:
              10 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Git Integration

                  Error rendering 'com.xiplink.jira.git.jira_git_plugin:git-issue-webpanel'. Please contact your Jira administrators.