<?xml version="1.0" encoding="utf-8"?>
<launchpad-bug id="1002126">
  <date_last_updated>2012-10-02 05:43:35.710249+00:00</date_last_updated>
  <api_links>
    <bug_api_link>https://api.launchpad.net/1.0/bugs/1002126</bug_api_link>
    <bug_owner_link>https://api.launchpad.net/1.0/~igorb-seattle</bug_owner_link>
    <milestone_link>https://api.launchpad.net/1.0/maria/+milestone/5.2</milestone_link>
    <linked_branches_collection_link>https://api.launchpad.net/1.0/bugs/1002126/linked_branches</linked_branches_collection_link>
    <activity_link>https://api.launchpad.net/1.0/bugs/1002126/activity</activity_link>
  </api_links>
  <bug_web_link>https://bugs.launchpad.net/bugs/1002126</bug_web_link>
  <owner>Igor Babaev</owner>
  <assignee>Oleksandr &quot;Sanja&quot; Byelkin</assignee>
  <milestone_title>Maria 5.2</milestone_title>
  <duplicate_link></duplicate_link>
  <duplicate_bug_id></duplicate_bug_id>
  <title>Assertion abort on SELECT @user_var</title>
  <status>Confirmed</status>
  <importance>High</importance>
  <created>2012-05-21 04:06:53.024967+00:00</created>
  <description>
<![CDATA[The following test case causes an assertion abort in MariaDB 5.2:

CREATE TABLE t1(a INT) ENGINE=InnoDB;
INSERT INTO t1 VALUES (0);
SELECT DISTINCT POW(COUNT(*), @a:=(SELECT 1 FROM t1 LEFT JOIN t1 AS t2 ON @a))
AS b FROM t1 GROUP BY a;
SELECT @a;
DROP TABLE t1;
CREATE TABLE t1(f1 INT, f2 INT);
INSERT INTO t1 VALUES (1,2),(2,3),(3,1);
CREATE TABLE t2(a INT);
INSERT INTO t2 VALUES (1);
SET @var=NULL;
SELECT @var:=(SELECT f2 FROM t2 WHERE @var) FROM t1 GROUP BY f1 ORDER BY f2 DESC
LIMIT 1;
SELECT @var;
DROP TABLE t1, t2;

The is no problem here with MaraiDB 5.5 though.]]>  </description>
  <activities>
    <activity datechanged="2012-05-21T04:06:53.024967+00:00">
      <oldvalue>
<![CDATA[]]>      </oldvalue>
      <newvalue>
<![CDATA[]]>      </newvalue>
      <whatchanged>bug</whatchanged>
      <person>Igor Babaev</person>
      <message>added bug</message>
    </activity>
    <activity datechanged="2012-05-21T04:07:02.890313+00:00">
      <oldvalue>
<![CDATA[New]]>      </oldvalue>
      <newvalue>
<![CDATA[Confirmed]]>      </newvalue>
      <whatchanged>maria: status</whatchanged>
      <person>Igor Babaev</person>
      <message></message>
    </activity>
    <activity datechanged="2012-05-21T04:07:06.585831+00:00">
      <oldvalue>
<![CDATA[Undecided]]>      </oldvalue>
      <newvalue>
<![CDATA[High]]>      </newvalue>
      <whatchanged>maria: importance</whatchanged>
      <person>Igor Babaev</person>
      <message></message>
    </activity>
    <activity datechanged="2012-05-21T04:07:29.449134+00:00">
      <oldvalue>
<![CDATA[]]>      </oldvalue>
      <newvalue>
<![CDATA[Oleksandr "Sanja" Byelkin (sanja-byelkin)]]>      </newvalue>
      <whatchanged>maria: assignee</whatchanged>
      <person>Igor Babaev</person>
      <message></message>
    </activity>
    <activity datechanged="2012-05-21T04:07:45.807536+00:00">
      <oldvalue>
<![CDATA[]]>      </oldvalue>
      <newvalue>
<![CDATA[5.2]]>      </newvalue>
      <whatchanged>maria: milestone</whatchanged>
      <person>Igor Babaev</person>
      <message></message>
    </activity>
    <activity datechanged="2012-10-01T15:25:50.076439+00:00">
      <oldvalue>
<![CDATA[Confirmed]]>      </oldvalue>
      <newvalue>
<![CDATA[In Progress]]>      </newvalue>
      <whatchanged>maria: status</whatchanged>
      <person>Oleksandr &quot;Sanja&quot; Byelkin</person>
      <message></message>
    </activity>
    <activity datechanged="2012-10-02T05:43:34.895801+00:00">
      <oldvalue>
<![CDATA[In Progress]]>      </oldvalue>
      <newvalue>
<![CDATA[Confirmed]]>      </newvalue>
      <whatchanged>maria: status</whatchanged>
      <person>Oleksandr &quot;Sanja&quot; Byelkin</person>
      <message></message>
    </activity>
  </activities>
  <comments>
    <comment commentlink="https://api.launchpad.net/1.0/maria/+bug/1002126/comments/1" datecreated="2012-05-21T04:15:02.356653+00:00">
      <person>Igor Babaev</person>
      <subject>
<![CDATA[Re: Assertion abort on SELECT @user_var]]>      </subject>
      <content>
<![CDATA[See also bug #57196  from bugs.mysql.com]]>      </content>
    </comment>
    <comment commentlink="https://api.launchpad.net/1.0/maria/+bug/1002126/comments/2" datecreated="2012-10-02T05:43:27.275133+00:00">
      <person>Oleksandr &quot;Sanja&quot; Byelkin</person>
      <subject>
<![CDATA[Re: Assertion abort on SELECT @user_var]]>      </subject>
      <content>
<![CDATA[The bug fixed in 5.3 and 5.5]]>      </content>
    </comment>
  </comments>
</launchpad-bug>
