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

Please support new ON DUPLICATE KEY UPDATE col=alias.col syntax

Details

    • New Feature
    • Status: Open (View Workflow)
    • Minor
    • Resolution: Unresolved
    • None
    • None

    Description

      Here: https://dev.mysql.com/doc/refman/8.0/en/insert-on-duplicate.html

      Oracle declares the use of VALUES() to be deprecated in statements like this.

      INSERT INTO tbl (id, col) 
        VALUES (1,'value')
      ON DUPLICATE KEY UPDATE col=VALUES(col)
      

      In their 8.20+ they specify the use of aliases like this.

      INSERT INTO tbl (id, col) 
        VALUES (1,'value') AS alias
      ON DUPLICATE KEY UPDATE col=alias.col
      

      It would be helpful (to the WordPress project among others) to avoid needing two different syntaxes in order to support both MariaDB and MySQL.

      Attachments

        Activity

          No workflow transitions have been executed yet.

          People

            Unassigned Unassigned
            OllieJones Oliver Jones
            Votes:
            0 Vote for this issue
            Watchers:
            2 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.