| Commit message (Collapse) | Author | Age | Files | Lines |
|\ |
|
| |\ |
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
This a an old legacy performance bug.
When a very selective range scan existed for the second table in a join,
and, at the same time, there was another range condition depending on the
fields of the first table, the optimizer chose a plan with
'Range checked for each record'. This plan was extremely inefficient in
comparison with the regular selective range scan.
As a matter of fact the range scan chosen for each record was the same as
that selective range scan.
Changed the test case for bug 24776 to preserve the old output for explain.
|
| | | |
|
| | | |
|
| | |
| | |
| | |
| | |
| | |
| | | |
MDEV-4812 Valgrind warnings (Invalid write) in dynamic_column_update_many on COLUMN_ADD
Fixed problem of working on wrong data (do not allow offset to out of string length).
|
| | | |
|
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
DATE_ADD with incorrect types
Fixing a typo: bit AND (&) was erroneously used instead of logical AND (&&)
|
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
MDEV-4643 MariaDB crashes consistently when trying a SELECT on VIEW with a UNION and an additional JOIN in SELECT
open derived temp tables *before* trying QUICK_SELECT for them,
handler::multi_range_read_info() needs an open table.
|
| | |
| | |
| | |
| | | |
don't ignore the return value fix_fields()
|
| | |
| | |
| | |
| | |
| | |
| | | |
bitmap_is_set(table->read_set, field_index))' fails on FROM subquery with fulltext search, derived_merge=on
remove emtpty Item_func_match::update_used_tables() method
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Cleanup: remove TIME_FUZZY_DATE.
Introduce TIME_FUZZY_DATES which means "very fuzzy, the resulting
value is only used for comparison. It can be invalid date, fine, as long as it can be
compared".
Updated many tests results (they're better now).
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Item_func_min_max::get_date() did not check the
returned value against the fuzzy_date flags, so
it could return a bad value to the caller that
expects a good date (e.h. CONVERT_TZ).
modified:
mysql-test/r/type_date.result
mysql-test/r/type_datetime.result
mysql-test/r/type_time.result
mysql-test/t/type_date.test
mysql-test/t/type_datetime.test
mysql-test/t/type_time.test
sql/item_func.cc
sql/item_timefunc.cc
sql/mysql_priv.h
sql/time.cc
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
modified:
mysql-test/r/func_time.result
mysql-test/t/func_time.test
sql/item_timefunc.cc
sql/mysql_priv.h
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
modified:
mysql-test/r/ps_2myisam.result
mysql-test/r/ps_3innodb.result
mysql-test/r/ps_4heap.result
mysql-test/r/ps_5merge.result
mysql-test/r/type_datetime_hires.result
mysql-test/suite/maria/r/ps_maria.result
mysql-test/t/type_datetime_hires.test
sql/item_timefunc.h
|
| | |
| | |
| | |
| | | |
mysql_derived_merge_for_insert() should not be called for views or derived tables which are not put (directly or via other views) in main SELECT_LEX "join list".
|
| | | |
|
|\ \ \
| |/ / |
|
| | |
| | |
| | |
| | | |
avoid divison by zero
|
| | |
| | |
| | |
| | |
| | | |
Fix agregate function resolution in derived tables (no name resolution over a derived table border)
|
|\ \ \ |
|
| | | |
| | | |
| | | |
| | | | |
- Rollback an earlier patch (was pushed into 5.3 instead of 5.5)
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
When iterating over a list of conditions using List_iterator
the function remove_eq_conds should skip all predicates that
replace a condition from the list. Otherwise it can come to
an infinite recursion.
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
<non-nullable datatime field> IS NULL in outer joins with
that in inner joins.
Previously such condition was transformed into the condition
<non-nullable datatime field> = 0 unless the field belonged
to an inner table of an outer join. In this case the predicate
was interpreted as for any other field.
Now if the field in the predicate <non-nullable datatime field> IS NULL
belongs to an inner table of an outer join the predicate is
transformed into the disjunction
<non-nullable datatime field> = 0 OR <non-nullable datatime field> IS NULL.
This is fully compatible with the semantics of such predicates in 5.5.
|
|/ / /
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
This bug was the result of incompleteness of the patch for bug mdev-4177.
When an OR condition is simplified to a single conjunct it is merged
into the embedding AND condition. Multiple equalities are also merged,
and any field item involved in those equality should acquire a pointer
to a the multiple equality formed by this merge.
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
fulltext search was initialized for all MATCH ... AGAINST items
at the end of the JOIN::optimize(). But since 5.3 derived tables
are initialized lazily on first use, very late in the sub_select().
Skip Item_func_match::init_search initialization if the corresponding
table isn't open yet; repeat fulltext initialization for all
not-yet-initialized MATCH ... AGAINST items after creating derived tables.
|
| | | |
|
| | |
| | |
| | |
| | |
| | | |
- When converting a subquery to a semi-join, propagate OPTION_SCHEMA_TABLE.
|
|\ \ \ |
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
In some cases, when using views the optimizer incorrectly determined
possible join orders for queries with nested outer and inner joins.
This could lead to invalid execution plans for such queries.
|
|\ \ \ \
| | |/ /
| |/| | |
|
| |\ \ \
| | | |/
| | |/| |
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
MultiPoint.
Need to check if the number of points is 0 for the polygon.
|
| | | |
| | | |
| | | |
| | | |
| | | | |
Forgotten DBUG_ASSERT should be replaced with the 'return error'.
|
| | | |
| | | |
| | | |
| | | | |
Item_default_value inherited form Item_field so should create temporary table field similary.
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
Additional fixes for possible overflows in length-related
calculations in 'spatial' implementations.
Checks added to the ::get_data_size() methods.
max_n_points decreased to occupy less 2G size. An
object of that size is practically inoperable anyway.
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
GROUP BY
Item_func_make_set wasn't taking into account the first argument when
calculating maybe_null.
sql/item_strfunc.cc:
rewrite Item_func_make_set, removing separate storage of the first argument
sql/item_strfunc.h:
rewrite Item_func_make_set, removing separate storage of the first argument
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
The bug was found by Alyssa Milburn.
If the number of points of a geometry feature read from
binary representation is greater than 0x10000000, then
the (uint32) (num_points * 16) will cut the higher byte,
which leads to various errors.
Fixed by additional check if (num_points > max_n_points).
|
| | | |
| | | |
| | | |
| | | | |
Fixed printing column_get finction.
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
The Geometry::get_mbr() function can return an error on
a bad data. We have to check for that and act respectively.
|
|\ \ \ \
| |_|_|/
|/| | | |
|
| | | |
| | | |
| | | |
| | | |
| | | | |
- Set MI_INFO::external_ref for MyISAM tables that are parts of myisamMRG table.
|
|/ / /
| | |
| | |
| | |
| | |
| | | |
uninitialised value) in remove_eq_conds on time functions with NULL argument
val_int() is expected to return 0 for NULL's
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
with decimals=NOT_FIXED_DEC it is possible to have 'decimals' larger
than 'max_length', it's not an error for temporal functions.
But when Item_func_numhybrid converts the value to DECIMAL_RESULT,
it must limit 'decimals' to be a valid scale of a decimal number.
|
| | |
| | |
| | |
| | |
| | |
| | | |
AVG() returns a double, its max_length is reasonably
limited by a double number length, even if the argument
is many Kbytes long.
|
| | |
| | |
| | |
| | |
| | |
| | | |
on CASE with different return types, GROUP_CONCAT, GROUP BY
Fix Item::get_date() to mark the item NULL when returning an error.
|
| | |
| | |
| | |
| | |
| | |
| | | |
This is a bug in the legacy code. It did not manifest itself because
it was masked by other bugs that were fixed by the patches for
mdev-4172 and mdev-4177.
|
| | |
| | |
| | |
| | |
| | | |
Field_enum incorrectly inherited decimals() from Field_string.
Field_enum should be always integer in numeric context.
|
|\ \ \ |
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
Do not include BLOB fields into the key to access the temporary
table created for a materialized view/derived table.
BLOB components are not allowed in keys.
|