summaryrefslogtreecommitdiff
path: root/sql/ha_ndbcluster.cc
diff options
context:
space:
mode:
authormskold@mysql.com <>2005-05-07 22:49:04 +0200
committermskold@mysql.com <>2005-05-07 22:49:04 +0200
commitbea71274f7a0321d10295e8327c7301b7636764d (patch)
tree7f3e221d2999fd7f2ea7f0582f0befa2a7f80c65 /sql/ha_ndbcluster.cc
parenta785052d7d7819da1d268b9eb0eb9f1071f2b0cf (diff)
parentcb8d2905aaea2d29b59cc819a1b35d74d9142d80 (diff)
downloadmariadb-git-bea71274f7a0321d10295e8327c7301b7636764d.tar.gz
Merge
Diffstat (limited to 'sql/ha_ndbcluster.cc')
-rw-r--r--sql/ha_ndbcluster.cc4
1 files changed, 4 insertions, 0 deletions
diff --git a/sql/ha_ndbcluster.cc b/sql/ha_ndbcluster.cc
index 8c80fba052c..e175b2b95f9 100644
--- a/sql/ha_ndbcluster.cc
+++ b/sql/ha_ndbcluster.cc
@@ -3050,8 +3050,10 @@ void ha_ndbcluster::start_bulk_insert(ha_rows rows)
m_rows_inserted= (ha_rows) 0;
if (rows == (ha_rows) 0)
+ {
/* We don't know how many will be inserted, guess */
m_rows_to_insert= m_autoincrement_prefetch;
+ }
else
m_rows_to_insert= rows;
@@ -4174,8 +4176,10 @@ ulonglong ha_ndbcluster::get_auto_increment()
Ndb *ndb= get_ndb();
if (m_rows_inserted > m_rows_to_insert)
+ {
/* We guessed too low */
m_rows_to_insert+= m_autoincrement_prefetch;
+ }
cache_size=
(int)
(m_rows_to_insert - m_rows_inserted < m_autoincrement_prefetch) ?