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

Primary key cannot be defined upon persistent virtual column

    XMLWordPrintable

Details

    • Task
    • Status: Open (View Workflow)
    • Major
    • Resolution: Unresolved
    • None
    • Virtual Columns
    • None

    Description

      ERROR 1903 (HY000): Primary key cannot be defined upon a computed column .

      Virtual column was a nice way to remove stuff like
      PRIMARY KEY (`COD_INV`, `COD_FAM`, `COD_MAG`, `COD_FIL`, `COD_ID_INV`)

      • It's a bad practice to use triggers
      • It's a bad practice to use hidden primary key ,
      • It's a bad practice to use virtual column .

      What could we advice that can be transparent to the application layer to fixe such bad design for InnoDB.

      Rewrite the application is not always a political correct answer.

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              stephane@skysql.com VAROQUI Stephane
              Votes:
              1 Vote for this issue
              Watchers:
              9 Start watching this issue

              Dates

                Created:
                Updated:

                Git Integration

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