mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-12-03 04:52:10 +00:00
19 lines
605 B
C++
19 lines
605 B
C++
#pragma once
|
|
|
|
#include <Core/QualifiedTableName.h>
|
|
#include <Interpreters/Context_fwd.h>
|
|
#include <Parsers/IAST_fwd.h>
|
|
#include <unordered_set>
|
|
|
|
|
|
namespace DB
|
|
{
|
|
using TableNamesSet = std::unordered_set<QualifiedTableName>;
|
|
|
|
/// Returns a list of all tables explicitly referenced in the create query of a specified table.
|
|
/// For example, a column default expression can use dictGet() and thus reference a dictionary.
|
|
/// Does not validate AST, works a best-effort way.
|
|
TableNamesSet getDependenciesFromCreateQuery(const ContextPtr & context, const QualifiedTableName & table_name, const ASTPtr & ast);
|
|
|
|
}
|