MCPcopy Create free account
hub / github.com/MariaDB/server / fill_recursive

Method fill_recursive

sql/sql_derived.cc:1194–1222  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1192*/
1193
1194bool TABLE_LIST::fill_recursive(THD *thd)
1195{
1196 bool rc= false;
1197 st_select_lex_unit *unit= get_unit();
1198 rc= with->instantiate_tmp_tables();
1199 while (!rc && !with->all_are_stabilized())
1200 {
1201 if (with->level > thd->variables.max_recursive_iterations)
1202 {
1203 push_warning_printf(thd, Sql_condition::WARN_LEVEL_WARN,
1204 ER_QUERY_RESULT_INCOMPLETE,
1205 ER_THD(thd, ER_QUERY_RESULT_INCOMPLETE),
1206 "max_recursive_iterations =",
1207 (ulonglong)thd->variables.max_recursive_iterations);
1208 break;
1209 }
1210 with->prepare_for_next_iteration();
1211 rc= unit->exec_recursive();
1212 }
1213 if (!rc)
1214 {
1215 TABLE *src= with->rec_result->table;
1216 rc =src->insert_all_rows_into_tmp_table(thd,
1217 table,
1218 &with->rec_result->tmp_table_param,
1219 true);
1220 }
1221 return rc;
1222}
1223
1224
1225/*

Callers 1

mysql_derived_fillFunction · 0.80

Calls 6

push_warning_printfFunction · 0.85
all_are_stabilizedMethod · 0.80
exec_recursiveMethod · 0.80

Tested by

no test coverage detected