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

Wrong data type for CREATE..SELECT sp_var

    XMLWordPrintable

Details

    • Bug
    • Status: Closed (View Workflow)
    • Major
    • Resolution: Fixed
    • 10.1(EOL), 10.2(EOL), 10.3(EOL)
    • 10.3.1
    • OTHER

    Description

      DROP PROCEDURE IF EXISTS p1;
      DELIMITER $$
      CREATE PROCEDURE p1()
      BEGIN
        DECLARE a INT;
        DECLARE b FLOAT;
        CREATE OR REPLACE TABLE t1 AS SELECT a, b;
      END;
      $$
      DELIMITER ;
      CALL p1;
      DESCRIBE t1;
      

      +-------+------------+------+-----+---------+-------+
      | Field | Type       | Null | Key | Default | Extra |
      +-------+------------+------+-----+---------+-------+
      | a     | bigint(11) | YES  |     | NULL    |       |
      | b     | double     | YES  |     | NULL    |       |
      +-------+------------+------+-----+---------+-------+
      

      The expected data types would be INT and FLOAT.

      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:

                Git Integration

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