mirror of
https://github.com/MariaDB/server.git
synced 2025-07-30 16:24:05 +03:00
caching of queries with isammerge tables forbiden using general way
SQL_SELECT_LIMIT as default will be applied only for SELECT statement if there was not explicit LIMIT clause correct table list passed to class constructor of select_update mysql-test/r/subselect.result: do not show limit if it is not explicit mysql-test/r/union.result: test of LIMIT + ORDER mysql-test/t/union.test: test of LIMIT + ORDER sql/ha_isammrg.h: caching of queries with isammerge tables forbiden sql/sql_cache.cc: removed check on isammerge sql/sql_lex.cc: tag of explicit limit in statement sql/sql_lex.h: tag of explicit limit in statement sql/sql_parse.cc: blanks in empty line removed no limit by default (SQL_SELECT_LIMIT as default will be applied only for SELECT statement if there was not explicit LIMIT clause) sql/sql_union.cc: reverted incorrect patch sql/sql_update.cc: reverted incorrect patch correct table list passed to class constructor sql/sql_yacc.yy: explicit LIMIT marked
This commit is contained in:
@ -1023,6 +1023,7 @@ void st_select_lex::init_query()
|
||||
ref_pointer_array= 0;
|
||||
select_n_having_items= 0;
|
||||
prep_where= 0;
|
||||
explicit_limit= 0;
|
||||
}
|
||||
|
||||
void st_select_lex::init_select()
|
||||
@ -1616,10 +1617,7 @@ void st_select_lex::print_limit(THD *thd, String *str)
|
||||
if (!thd)
|
||||
thd= current_thd;
|
||||
|
||||
if ((select_limit != thd->variables.select_limit &&
|
||||
this == &thd->lex->select_lex) ||
|
||||
(select_limit != HA_POS_ERROR && this != &thd->lex->select_lex) ||
|
||||
offset_limit != 0L)
|
||||
if (explicit_limit)
|
||||
{
|
||||
str->append(" limit ", 7);
|
||||
char buff[20];
|
||||
|
Reference in New Issue
Block a user