Uploaded image for project: 'MariaDB Server'
  1. MariaDB Server
  2. MDEV-10142 PL/SQL parser
  3. MDEV-10866

Extend PREPARE and EXECUTE IMMEDIATE to understand expressions

    XMLWordPrintable

Details

    Description

      Currently, PREPARE understands string literals or user variables:

      PREPARE stmt1 FROM 'SELECT 1';
      SET @s='SELECT 1';
      PREPARE stmt2 FROM @s;
      

      We'll extend PREPARE and EXECUTE IMMEDIATE to understand (almost) any kind of expressions:

      PREPARE stmt FROM CONCAT('SELECT * FROM ', table_name);
      

      Using stored functions and subselects as a prepare source is out of scope of this task.

      Attachments

        Issue Links

          Activity

            People

              bar Alexander Barkov
              bar Alexander Barkov
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0d
                  0d
                  Logged:
                  Time Spent - 3d 3h
                  3d 3h

                  Git Integration

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