Uploaded image for project: 'MariaDB Server'
  1. MariaDB Server
  2. MDEV-33084

LASTVAL(t1) and LASTVAL(T1) do not work well with lower-case-table-names=0

    XMLWordPrintable

Details

    Description

      I run this script:

      create or replace sequence t1;
      create or replace sequence T1;
      select nextval(t1), lastval(t1);
      select nextval(T1), lastval(T1);
      select lastval(t1), lastval(T1);
      

      The last statement returnt these results:

      +-------------+-------------+
      | lastval(t1) | lastval(T1) |
      +-------------+-------------+
      |        NULL |        NULL |
      +-------------+-------------+
      

      Look wrong. The expected result should be:

      +-------------+-------------+
      | lastval(t1) | lastval(T1) |
      +-------------+-------------+
      |           1 |           1 |
      +-------------+-------------+
      

      Attachments

        Issue Links

          Activity

            People

              bar Alexander Barkov
              bar Alexander Barkov
              Votes:
              0 Vote for this issue
              Watchers:
              2 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.