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

Assertion `0' failed in Field_blob_compressed::new_key_field

    XMLWordPrintable

Details

    • Bug
    • Status: Closed (View Workflow)
    • Major
    • Resolution: Duplicate
    • 10.3(EOL), 10.4(EOL)
    • N/A
    • N/A
    • None

    Description

      --source include/have_innodb.inc
      set join_cache_level=3;
       
      create table t1 (a1 text compressed) engine=innodb;
      insert into t1 values ('foo'),('bar');
       
      create table t2 (bl text, cv varchar(30)) engine=innodb ;
      insert into t2  values ('foo1','t');
       
      create table t3 (cv varchar(30)) engine=innodb;
      insert into t3 values ('az');
       
      select 1 from t1 where (a1) in (select t2.bl from t2 join t3 on t2.cv = t3.cv);
       
      drop table t1,t2,t3;
      

      10.3 352e7667877ec6603aff523

      #4  0x00007f08e8408428 in __GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:54
      #5  0x00007f08e840a02a in __GI_abort () at abort.c:89
      #6  0x00007f08e8400bd7 in __assert_fail_base (fmt=<optimized out>, assertion=assertion@entry=0x5643c42f8d18 "0", file=file@entry=0x5643c42f8cb0 "/10.3/sql/field.h", line=line@entry=3874, function=function@entry=0x5643c42fec60 <Field_blob_compressed::new_key_field(st_mem_root*, TABLE*, unsigned char*, unsigned int, unsigned char*, unsigned int)::__PRETTY_FUNCTION__> "virtual Field* Field_blob_compressed::new_key_field(MEM_ROOT*, TABLE*, uchar*, uint32, uchar*, uint)") at assert.c:92
      #7  0x00007f08e8400c82 in __GI___assert_fail (assertion=0x5643c42f8d18 "0", file=0x5643c42f8cb0 "/10.3/sql/field.h", line=3874, function=0x5643c42fec60 <Field_blob_compressed::new_key_field(st_mem_root*, TABLE*, unsigned char*, unsigned int, unsigned char*, unsigned int)::__PRETTY_FUNCTION__> "virtual Field* Field_blob_compressed::new_key_field(MEM_ROOT*, TABLE*, uchar*, uint32, uchar*, uint)") at assert.c:101
      #8  0x00005643c383b690 in Field_blob_compressed::new_key_field (this=0x7f08980082d0, root=0x7f0898006040, new_table=0x7f08980a6b30, new_ptr=0x7f08980187e1 "", length=0, new_null_ptr=0x7f08980187e0 "", new_null_bit=1) at /10.3/sql/field.h:3874
      #9  0x00005643c35c1aa1 in store_key::store_key (this=0x7f089803d968, thd=0x7f0898000b00, field_arg=0x7f08980082d0, ptr=0x7f08980187e1 "", null=0x7f08980187e0 "", length=0) at /10.3/sql/sql_select.h:1844
      #10 0x00005643c35c1cf1 in store_key_field::store_key_field (this=0x7f089803d968, thd=0x7f0898000b00, to_field_arg=0x7f08980082d0, ptr=0x7f08980187e1 "", null_ptr_arg=0x7f08980187e0 "", length=0, from_field=0x7f0898184128, name_arg=0x7f089803d958 "test.t2.bl") at /10.3/sql/sql_select.h:1901
      #11 0x00005643c358d605 in get_store_key (thd=0x7f0898000b00, keyuse=0x7f0898017dd8, used_tables=0, key_part=0x7f08980187b8, key_buff=0x7f08980187e0 "", maybe_null=1) at /10.3/sql/sql_select.cc:10155
      #12 0x00005643c358d0c8 in create_ref_for_key (join=0x7f08980159d8, j=0x7f089803d180, org_keyuse=0x7f0898017dd8, allow_full_scan=true, used_tables=4611686018427387911) at /10.3/sql/sql_select.cc:10070
      #13 0x00005643c358bdd6 in JOIN::get_best_combination (this=0x7f08980159d8) at /10.3/sql/sql_select.cc:9737
      #14 0x00005643c3573d4e in JOIN::optimize_stage2 (this=0x7f08980159d8) at /10.3/sql/sql_select.cc:1934
      #15 0x00005643c3573c4f in JOIN::optimize_inner (this=0x7f08980159d8) at /10.3/sql/sql_select.cc:1913
      #16 0x00005643c357218b in JOIN::optimize (this=0x7f08980159d8) at /10.3/sql/sql_select.cc:1449
      #17 0x00005643c357c132 in mysql_select (thd=0x7f0898000b00, tables=0x7f0898012a08, wild_num=0, fields=..., conds=0x7f0898015688, og_num=0, order=0x0, group=0x0, having=0x0, proc_param=0x0, select_options=2147748608, result=0x7f08980159b0, unit=0x7f08980049d0, select_lex=0x7f0898005150) at /10.3/sql/sql_select.cc:4225
      #18 0x00005643c356dbce in handle_select (thd=0x7f0898000b00, lex=0x7f0898004908, result=0x7f08980159b0, setup_tables_done_option=0) at /10.3/sql/sql_select.cc:382
      #19 0x00005643c3535453 in execute_sqlcom_select (thd=0x7f0898000b00, all_tables=0x7f0898012a08) at /10.3/sql/sql_parse.cc:6290
      #20 0x00005643c352bec0 in mysql_execute_command (thd=0x7f0898000b00) at /10.3/sql/sql_parse.cc:3820
      #21 0x00005643c353978c in mysql_parse (thd=0x7f0898000b00, rawbuf=0x7f0898012818 "select 1 from t1 where (a1) in (select t2.bl from t2 join t3 on t2.cv = t3.cv)", length=78, parser_state=0x7f08e1a73460, is_com_multi=false, is_next_command=false) at /10.3/sql/sql_parse.cc:7833
      #22 0x00005643c352629b in dispatch_command (command=COM_QUERY, thd=0x7f0898000b00, packet=0x7f089815fee1 "select 1 from t1 where (a1) in (select t2.bl from t2 join t3 on t2.cv = t3.cv)", packet_length=78, is_com_multi=false, is_next_command=false) at /10.3/sql/sql_parse.cc:1855
      #23 0x00005643c3524ba9 in do_command (thd=0x7f0898000b00) at /10.3/sql/sql_parse.cc:1401
      #24 0x00005643c369cce6 in do_handle_one_connection (connect=0x5643c69557d0) at /10.3/sql/sql_connect.cc:1403
      #25 0x00005643c369ca22 in handle_one_connection (arg=0x5643c69557d0) at /10.3/sql/sql_connect.cc:1308
      #26 0x00005643c404d340 in pfs_spawn_thread (arg=0x5643c689b030) at /10.3/storage/perfschema/pfs.cc:1862
      #27 0x00007f08e90456ba in start_thread (arg=0x7f08e1a74700) at pthread_create.c:333
      #28 0x00007f08e84da41d in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:109
      

      Attachments

        Issue Links

          Activity

            People

              svoj Sergey Vojtovich
              alice Alice Sherepa
              Votes:
              0 Vote for this issue
              Watchers:
              3 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.