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

Allow DELETE FROM RETURNING to be used with INSERT INTO

    XMLWordPrintable

Details

    Description

      First discussed here: https://lists.launchpad.net/maria-discuss/msg02647.html

      Just regarding the RETURNING feature introduced into MariaDB 10.0.5 https://mariadb.com/kb/en/mariadb/delete/

      It would be useful, similar to the OUTPUT clause in MSSQL, if we could INSERT the data sent back from a returning clause in a single statement. Something like…

      CREATE TABLE deleted_ids
      (
                      Id INT NOT NULL PRIMARY KEY
      );
       
      INSERT INTO deleted_ids
      DELETE FROM t1
      WHERE id < 999
      RETURNING id;
      

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              GeoffMontee Geoff Montee (Inactive)
              Votes:
              8 Vote for this issue
              Watchers:
              6 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.