summaryrefslogtreecommitdiff
path: root/sql/sql_yacc.yy
diff options
context:
space:
mode:
authorkroki/tomash@moonlight.intranet <>2006-11-29 15:51:53 +0300
committerkroki/tomash@moonlight.intranet <>2006-11-29 15:51:53 +0300
commit50e3b321707442e3c44216d2f1f5026340336c4c (patch)
tree3d72a6842c090b7a45ece2e39fc9a00c1917ba83 /sql/sql_yacc.yy
parent6fd6e099c939249b49de740d27ac58a2cb8b2e60 (diff)
downloadmariadb-git-50e3b321707442e3c44216d2f1f5026340336c4c.tar.gz
BUG#20637: "load data concurrent infile" locks the table
Note that we ignore CONCURRENT if LOAD DATA CONCURRENT is used from inside a stored routine and MySQL is compiled with Query Cache support (this is not in the manual). The problem was that the condition test of "we are inside stored routine" was reversed, thus CONCURRENT _worked only_ from stored routine. The solution is to use proper condition test. No test case is provided because the test case would require a large amount of input, and it's hard to tell is SELECT is really blocked or just slow (subject to race).
Diffstat (limited to 'sql/sql_yacc.yy')
-rw-r--r--sql/sql_yacc.yy2
1 files changed, 2 insertions, 0 deletions
diff --git a/sql/sql_yacc.yy b/sql/sql_yacc.yy
index 6f24a42c07c..7347a2aabb8 100644
--- a/sql/sql_yacc.yy
+++ b/sql/sql_yacc.yy
@@ -7031,6 +7031,8 @@ load_data_lock:
Ignore this option in SP to avoid problem with query cache
*/
if (Lex->sphead != 0)
+ $$= YYTHD->update_lock_default;
+ else
#endif
$$= TL_WRITE_CONCURRENT_INSERT;
}