There are no limits on the maximum size of the result for the subquery. * Since the result of the query is not the result of the entire query. */
| 389 | * Since the result of the query is not the result of the entire query. |
| 390 | */ |
| 391 | ContextPtr getSubqueryContext(const ContextPtr & context) |
| 392 | { |
| 393 | auto subquery_context = Context::createCopy(context); |
| 394 | Settings subquery_settings = context->getSettingsCopy(); |
| 395 | subquery_settings[Setting::max_result_rows] = 0; |
| 396 | subquery_settings[Setting::max_result_bytes] = 0; |
| 397 | subquery_settings[Setting::implicit_table_at_top_level] = ""; |
| 398 | /// The calculation of extremes does not make sense and is not necessary (if you do it, then the extremes of the subquery can be taken for whole query). |
| 399 | subquery_settings[Setting::extremes] = false; |
| 400 | subquery_context->setSettings(subquery_settings); |
| 401 | return subquery_context; |
| 402 | } |
| 403 | |
| 404 | void rewriteMultipleJoins(ASTPtr & query, const TablesWithColumns & tables, const String & database, const Settings & settings) |
| 405 | { |
no test coverage detected