summaryrefslogtreecommitdiff
path: root/sql/sql_join_cache.cc
diff options
context:
space:
mode:
authorSergey Petrunya <psergey@askmonty.org>2012-08-27 08:44:58 +0400
committerSergey Petrunya <psergey@askmonty.org>2012-08-27 08:44:58 +0400
commit8eb16159e19b38e67728fca7c7f316f921a2c7e0 (patch)
treec6cf6b7e40dde9d8c0edb5bf5674ca1b434bea8c /sql/sql_join_cache.cc
parentfdab0300c1e11511df4bae3072eb642fdc222ff8 (diff)
downloadmariadb-git-8eb16159e19b38e67728fca7c7f316f921a2c7e0.tar.gz
Cassandra storage engine: BKA support
- We use HA_MRR_NO_ASSOC ("optimizer_switch=join_cache_hashed") mode - Not able to use BKA's buffers yet. - There is a variable to control batch size - There are status counters. - Nedeed to make some fixes in BKA code (to be checked with Igor)
Diffstat (limited to 'sql/sql_join_cache.cc')
-rw-r--r--sql/sql_join_cache.cc5
1 files changed, 4 insertions, 1 deletions
diff --git a/sql/sql_join_cache.cc b/sql/sql_join_cache.cc
index f953cf4df57..d785366ae69 100644
--- a/sql/sql_join_cache.cc
+++ b/sql/sql_join_cache.cc
@@ -3876,8 +3876,11 @@ int JOIN_TAB_SCAN_MRR::next()
If a record in in an incremental cache contains no fields then the
association for the last record in cache will be equal to cache->end_pos
*/
+ /*
+ psergey: this makes no sense where HA_MRR_NO_ASSOC is used.
DBUG_ASSERT(cache->buff <= (uchar *) (*ptr) &&
(uchar *) (*ptr) <= cache->end_pos);
+ */
if (join_tab->table->vfield)
update_virtual_fields(join->thd, join_tab->table);
}
@@ -4543,7 +4546,7 @@ bool JOIN_CACHE_BKAH::prepare_look_for_matches(bool skip_last)
{
last_matching_rec_ref_ptr= next_matching_rec_ref_ptr= 0;
if (no_association &&
- (curr_matching_chain= get_matching_chain_by_join_key()))
+ !(curr_matching_chain= get_matching_chain_by_join_key())) //psergey: added '!'
return 1;
last_matching_rec_ref_ptr= get_next_rec_ref(curr_matching_chain);
return 0;