summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSergei Golubchik <serg@mariadb.org>2015-05-05 22:05:05 +0200
committerSergei Golubchik <serg@mariadb.org>2015-05-05 22:05:05 +0200
commitc09c265ac42279d8785354f34f096f51df9226e2 (patch)
tree9df108c4aa92a21f0641ff8caf36ca34db9607f8
parentf5b05a11c1d8f5817b957f5397c288146a348b29 (diff)
downloadmariadb-git-c09c265ac42279d8785354f34f096f51df9226e2.tar.gz
Fix MDEV-8090 in tabmysql.cpp
-rw-r--r--storage/connect/tabmysql.cpp11
1 files changed, 9 insertions, 2 deletions
diff --git a/storage/connect/tabmysql.cpp b/storage/connect/tabmysql.cpp
index 66f275796b5..b18e4da2ec4 100644
--- a/storage/connect/tabmysql.cpp
+++ b/storage/connect/tabmysql.cpp
@@ -1060,9 +1060,16 @@ bool TDBMYSQL::ReadKey(PGLOBAL g, OPVAL op, const void *key, int len)
int oldlen = Query->GetLength();
if (!key || op == OP_NEXT ||
- Mode == MODE_UPDATE || Mode == MODE_DELETE)
+ Mode == MODE_UPDATE || Mode == MODE_DELETE) {
+ if (!key && Mode == MODE_READX) {
+ // This is a false indexed read
+ m_Rc = Myc.ExecSQL(g, Query->GetStr());
+ Mode = MODE_READ;
+ return (m_Rc == RC_FX) ? true : false;
+ } // endif key
+
return false;
- else if (op == OP_FIRST) {
+ } else if (op == OP_FIRST) {
if (To_CondFil) {
oom = Query->Append(" WHERE ");