- 16 Apr, 2018 1 commit
-
-
Igor Babaev authored
Any expensive WHERE condition for a table-less query with implicit aggregation was lost. As a result the used aggregate functions were calculated over a non-empty set of rows even in the case when the condition was false.
-
- 13 Apr, 2018 1 commit
-
-
Daniel Black authored
Also clarify which --{no-,}default* options, must be first. Sample output: $ client/mysql --help client/mysql Ver 15.1 Distrib 5.5.59-MariaDB, for Linux (x86_64) using readline 5.1 Copyright (c) 2000, 2017, Oracle, MariaDB Corporation Ab and others. Usage: client/mysql [OPTIONS] [database] Default options are read from the following files in the given order: /etc/my.cnf /etc/mysql/my.cnf ~/.my.cnf The following groups are read: mysql client client-server client-mariadb The following options may be given as the first argument: --print-defaults Print the program argument list and exit. --no-defaults Don't read default options from any option file. The following specify which files/groups are read (specified before other options): --defaults-file=# Only read default options from the given file #. --defaults-extra-file=# Read this file after the global files are read. --defaults-group-suffix=# Additionally read default groups with # appended as a suffix. tests running from build directory: TEST: print defaults ignored as not first $ sql/mysqld --no-defaults --print-defaults --lc-messages-dir=${PWD}/sql/share TEST: no startup occurs as --print-defaults specified $ sql/mysqld --print-defaults --lc-messages-dir=${PWD}/sql/share sql/mysqld would have been started with the following arguments: --lc-messages-dir=/home/dan/repos/build-mariadb-5.5/sql/share TEST: default args can't be anywhere $ client/mysql --user=bob --defaults-file=/etc/my.cnf client/mysql: unknown variable 'defaults-file=/etc/my.cnf' $ client/mysql --user=bob --defaults-group-suffix=.group client/mysql: unknown variable 'defaults-group-suffix=.group' /etc/my.cnf: [client-server.group] socket=/var/lib/mysql-multi/group/mysqld.sock user=bob /etc/my.other.cnf: socket=/var/lib/mysql-other/mysqld.sock TEST: defaults file read and suffix also applied $ client/mysql --defaults-file=/etc/my.other.cnf --defaults-group-suffix=.group ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/lib/mysql-other/mysqld.sock' (2) TEST: defaults extra file $ client/mysql --defaults-extra-file=/etc/my.other.cnf --defaults-group-suffix=.group ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/lib/mysql-other/mysqld.sock' (2)
-
- 08 Apr, 2018 1 commit
-
-
Alexey Botchkov authored
condition fixed.
-
- 07 Apr, 2018 1 commit
-
-
Alexey Botchkov authored
handler::ha_create_handler_files shouldn't call the mark_trx_read_write() for the temporary table.
-
- 04 Apr, 2018 1 commit
-
-
Alexander Barkov authored
MDEV-15624 Changing the default character set to utf8mb4 changes query evaluation in a very surprising way
-
- 03 Apr, 2018 3 commits
-
-
Sergei Golubchik authored
-
Sergei Golubchik authored
warning: format '%p' expects argument of type 'void *', but argument 4 has type 'long int'
-
Alexander Barkov authored
-
- 27 Mar, 2018 2 commits
-
-
Varun Gupta authored
For this case we have a view that is mergeable but we are not able to merge it in the parent select because that would exceed the maximum tables allowed in the join list, so we materialise this view TABLE_LIST::dervied is NULL for such views, it is only set for views which have ALGORITHM=TEMPTABLE Fixed by making sure TABLE_LIST::derived is set for views that could not be merged
-
Alexander Barkov authored
A simple patch fixing the problem in 5.5. Note, a full patch was previously fixed to 10.3.
-
- 21 Mar, 2018 3 commits
-
-
Varun Gupta authored
Conversion of a subquery to a semi-join is blocked when we have an IN subquery predicate in the on_expr of an outer join. Currently this scenario is handled but the cases when an IN subquery predicate is wrapped inside a Item_in_optimizer item then this blocking is not done.
-
Oleksandr Byelkin authored
Detection of first execution of PS fixed. More debug info.
-
Varun Gupta authored
For the query having an IN subquery with no tables, we were converting the subquery with an expression between the left part and the select list of the subquery . This can give incorrect results when we have a condition in the subquery with a dual table (as this is treated as a no table). The fix is that we don't do this conversion when we have conds in the subquery with a dual table.
-
- 20 Mar, 2018 2 commits
-
-
Marko Mäkelä authored
mem_heap_create_block(): Poison the payload area until mem_heap_alloc() unpoisons it.
-
Eugene Kosov authored
-
- 19 Mar, 2018 1 commit
-
-
Eugene Kosov authored
Learn both valgrind and asan to catch this bug: mem_heap_t* heap = mem_heap_create(1024); byte* p = reinterpret_cast<byte*>(heap) + sizeof(mem_heap_t); *p = 123; Overflows of the last allocation in a block will be catched too. mem_heap_create_block(): poison newly allocated memory
-
- 14 Mar, 2018 1 commit
-
-
Vladislav Vaintroub authored
Backport from 10.2
-
- 11 Mar, 2018 1 commit
-
-
Varun Gupta authored
The issue is that we are creating a materialised table with key of length 0 which is incorrect, we should disable materialisation for such a case.
-
- 24 Feb, 2018 1 commit
-
-
Daniel Black authored
-
- 15 Feb, 2018 1 commit
-
-
Sergei Golubchik authored
-
- 14 Feb, 2018 2 commits
-
-
Sergei Golubchik authored
use the correct handlerton when looking for TRANSACTIONAL=1 support
-
Sergei Golubchik authored
MDEV-13748 Assertion `status_var.local_memory_used == 0 || !debug_assert_on_not_freed_memory' failed in virtual THD::~THD after query with INTERSECT my_safe_alloca()/my_safe_afree() work as alloca() or malloc()/free() depending on the memory size to allocate, that is, depending on reclength here. They only work correctly if reclength doesn't change in the middle.
-
- 11 Feb, 2018 2 commits
-
-
Sergei Golubchik authored
-
Sergei Golubchik authored
proper fix replacing the hack from b80fa400 don't confuse length of the data area (reclength) with the offset to the "deleted" mark.
-
- 30 Jan, 2018 3 commits
-
-
Vicențiu Ciorbaru authored
-
Vicențiu Ciorbaru authored
Whenever one copies an IO_CACHE struct, one must remember to call setup_io_cache, if not, the IO_CACHE's current_pos and end_pos self-references will point to the previous struct's memory, which could go out of scope. Commit 90038693 fixes this problem in a more general fashion by removing the self-references altogether, but for 5.5 we'll keep the old behaviour.
-
Vicențiu Ciorbaru authored
MDEV-15014 Assertion `m_cache_lock_status == LOCKED_NO_WAIT || m_cache_status == DISABLE_REQUEST' failed in Query_cache::free_cache on startup The assert guards against not-locked or not-requested query cache disabling. If during startup we disable query cache, we failed to request disabling.
-
- 29 Jan, 2018 1 commit
-
-
Marko Mäkelä authored
To disable debug instrumentation, save and restore the original value of the variable DEBUG_DBUG. Assigning -d,... will enable the output of a lot of unrelated DBUG messages to the server error log.
-
- 24 Jan, 2018 3 commits
-
-
Oleksandr Byelkin authored
First roll back changes, then free Items which can lead to memory freeing.
-
Oleksandr Byelkin authored
-
Sergei Golubchik authored
also cover USE and other built-in commands
-
- 23 Jan, 2018 9 commits
-
-
Marko Mäkelä authored
mem_heap_free_heap_top(): Remove UNIV_MEM_ASSERT_W() and unpoison the memory region first, because part of it may have been poisoned by an earlier mem_heap_free_top() call. Poison the address range at the end. mem_heap_block_free(): Poison the address range at the end. UNIV_MEM_ASSERT_AND_ALLOC(): Replace with UNIV_MEM_ALLOC(). We want to keep the address ranges poisoned (unaccessible) as long as possible. UNIV_MEM_ASSERT_AND_FREE(): Replace with UNIV_MEM_FREE().
-
Marko Mäkelä authored
-
Oleksandr Byelkin authored
MDEV-14957: JOIN::prepare gets unusable "conds" as argument Do not touch merged derived (it is irreversible) Fix first argument of in_optimizer for calls possible before fix_fields()
-
Oleksandr Byelkin authored
-
Sachin Setiya authored
Problem:- If we create table using myisam/aria then this crashes the server. CREATE TABLE t1(a bit(1), b int auto_increment , index(a,b)); insert into t1 values(1,1); Or this query CREATE TABLE t1 (b BIT(1), pk INTEGER AUTO_INCREMENT PRIMARY KEY); ALTER TABLE t1 ADD INDEX(b,pk); INSERT INTO t1 VALUES (1,b'1'); ALTER TABLE t1 DROP PRIMARY KEY; Reason:- The reason for this is 1st- find_ref_key() finds what key an auto_increment field belongs to by comparing key_part->offset and field->ptr. But BIT fields might have zero length in the record, so a key might have many key parts with the same offset. That is, comparing offsets cannot uniquely identify the correct key part. 2nd- Since next_number_key_offset is zero it myisam/aria will think that auto_increment is in first part of key. 3nd- myisam/aria will call retrieve_auto_key which will see first key_part field as a bit field and call assert(0) Solution:- Many key parts might have the same offset, but BIT fields do not support auto_increment. So, we can skip all key parts over BIT fields, and then comparing offsets will be unambiguous.
-
Daniel Black authored
-
Karim Geiger authored
-
Daniel Black authored
-
Daniel Black authored
-