mirror of
https://github.com/MariaDB/server.git
synced 2026-05-15 11:27:39 +02:00
Merge branch '10.0' into 10.1
referenced_by_foreign_key2(), needed for InnoDB to compile, was taken from 10.0-galera
This commit is contained in:
commit
530a6e7481
361 changed files with 9482 additions and 4583 deletions
|
|
@ -195,8 +195,6 @@ public:
|
|||
PREV_BITS(key_part_map, max_loose_keypart+1) && // (3)
|
||||
!key_uses_partial_cols(s->table->s, key))
|
||||
{
|
||||
/* Ok, can use the strategy */
|
||||
part1_conds_met= TRUE;
|
||||
if (s->quick && s->quick->index == key &&
|
||||
s->quick->get_type() == QUICK_SELECT_I::QS_TYPE_RANGE)
|
||||
{
|
||||
|
|
@ -205,6 +203,12 @@ public:
|
|||
}
|
||||
DBUG_PRINT("info", ("Can use LooseScan scan"));
|
||||
|
||||
if (found_part & 1)
|
||||
{
|
||||
/* Can use LooseScan on ref access if the first key part is bound */
|
||||
part1_conds_met= TRUE;
|
||||
}
|
||||
|
||||
/*
|
||||
Check if this is a special case where there are no usable bound
|
||||
IN-equalities, i.e. we have
|
||||
|
|
@ -212,11 +216,13 @@ public:
|
|||
outer_expr IN (SELECT innertbl.key FROM ...)
|
||||
|
||||
and outer_expr cannot be evaluated yet, so it's actually full
|
||||
index scan and not a ref access
|
||||
index scan and not a ref access.
|
||||
We can do full index scan if it uses index-only.
|
||||
*/
|
||||
if (!(found_part & 1 ) && /* no usable ref access for 1st key part */
|
||||
s->table->covering_keys.is_set(key))
|
||||
{
|
||||
part1_conds_met= TRUE;
|
||||
DBUG_PRINT("info", ("Can use full index scan for LooseScan"));
|
||||
|
||||
/* Calculate the cost of complete loose index scan. */
|
||||
|
|
@ -384,6 +390,7 @@ public:
|
|||
bool create_sj_weedout_tmp_table(THD *thd);
|
||||
};
|
||||
|
||||
int setup_semijoin_loosescan(JOIN *join);
|
||||
int setup_semijoin_dups_elimination(JOIN *join, ulonglong options,
|
||||
uint no_jbuf_after);
|
||||
void destroy_sj_tmp_tables(JOIN *join);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue