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

Malformed error message for ER_KEY_CONTAINS_PERIOD_FIELDS

Details

    Description

      10.5 f544a712

      MariaDB [test]> create or replace table t1 (a int, s date, e date, period for p(s,e), primary key(a, s, p without overlaps));
      ERROR 4170 (HY000): Key `(null)` cannot explicitly include column `s`
       
      MariaDB [test]> create or replace table t1 (a int, s date, e date, period for p(s,e), unique(a, s, p without overlaps));
      ERROR 4170 (HY000): Key `(null)` cannot explicitly include column `s`
      

      It only populates the name when it is explicitly provided:

      MariaDB [test]> create or replace table t1 (a int, s date, e date, period for p(s,e), unique ind(a, s, p without overlaps));
      ERROR 4170 (HY000): Key `ind` cannot explicitly include column `s`
      

      Of course it is not always done for UNIQUE and almost never done for PRIMARY KEY (as an explicit name for primary key is ignored and causes a warning).

      Attachments

        Activity

          Transition Time In Source Status Execution Times
          Nikita Malyavin made transition -
          Open In Progress
          159d 10h 3m 1
          Nikita Malyavin made transition -
          In Progress In Review
          5d 4h 23m 1
          Oleksandr Byelkin made transition -
          In Review Stalled
          3d 4h 46m 1
          Nikita Malyavin made transition -
          Stalled Closed
          9d 17h 24m 1

          People

            nikitamalyavin Nikita Malyavin
            elenst Elena Stepanova
            Votes:
            0 Vote for this issue
            Watchers:
            3 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.