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

reexecution of prepared statement return wrong first row data

    XMLWordPrintable

Details

    Description

      tested, but not reproduced on 10.2, 10.3 server

      There is an issue when reusing multiple time COM_STMT_EXECUTE.

      Join to this issue are 2 files (sql + java test) to reproduced the issue.
      Executing multiple time the same query on different connection with same parameters sometimes return a strange first resultset binary row.

      First row content is normally :

      +--------------------------------------------------+
      |  0  1  2  3  4  5  6  7   8  9  a  b  c  d  e  f |
      +--------------------------------------------------+------------------+
      | 91 00 00 11 00 00 F8 00  13 31 31 38 32 39 36 31 | .........1182961 |
      | 30 39 38 34 35 31 39 38  38 34 38 32 13 31 31 36 | 098451988482.116 |
      | 32 35 33 33 33 37 30 36  38 37 30 30 34 36 37 33 | 2533370687004673 |
      | 01 01 01 24 33 65 30 30  39 31 65 65 2D 39 31 30 | ...$3e0091ee-910 |
      | 35 2D 31 31 65 61 2D 38  32 66 30 2D 30 30 35 30 | 5-11ea-82f0-0050 |
      | 35 36 38 64 36 62 62 61  0A 00 00 00 00 00 00 00 | 568d6bba........ |
      | 3C 00 00 00 00 00 00 00  24 33 65 30 30 39 32 30 | <.......$3e00920 |
      | 37 2D 39 31 30 35 2D 31  31 65 61 2D 38 32 66 30 | 7-9105-11ea-82f0 |
      | 2D 30 30 35 30 35 36 38  64 36 62 62 61 01 00 00 | -0050568d6bba... |
      | 00 00 00 00 00                                   | .....            |
      +--------------------------------------------------+------------------+
      

      but sometime is :

      +--------------------------------------------------+
      |  0  1  2  3  4  5  6  7   8  9  a  b  c  d  e  f |
      +--------------------------------------------------+------------------+
      | 4C 00 00 11 00 00 00 00  00 00 00 00 00 00 00 00 | L............... |
      | 00 00 00 00 00 01 3C 00  00 00 00 00 00 00 24 33 | ......<.......$3 |
      | 65 30 31 31 38 62 64 2D  39 31 30 35 2D 31 31 65 | e0118bd-9105-11e |
      | 61 2D 38 32 66 30 2D 30  30 35 30 35 36 38 64 36 | a-82f0-0050568d6 |
      | 62 62 61 00 00 00 00 00  04 00 00 00 00 00 00 00 | bba............. |
      +--------------------------------------------------+------------------+
      

      Attachments

        Activity

          People

            shulga Dmitry Shulga
            diego dupin Diego Dupin
            Votes:
            1 Vote for this issue
            Watchers:
            7 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.