Skip to content

Commit

Permalink
Fix "Invalid storage definition in metadata file" for parametrized views
Browse files Browse the repository at this point in the history
Signed-off-by: Azat Khuzhin <a.khuzhin@semrush.com>
  • Loading branch information
azat committed Mar 3, 2024
1 parent a1d1f76 commit 24e373a
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion src/Databases/DatabaseOnDisk.cpp
Expand Up @@ -83,7 +83,13 @@ std::pair<String, StoragePtr> createTableFromAST(
ColumnsDescription columns;
ConstraintsDescription constraints;

if (!ast_create_query.is_dictionary)
bool has_columns = true;
if (ast_create_query.is_dictionary)
has_columns = false;
if (ast_create_query.isParameterizedView())
has_columns = false;

if (has_columns)
{
/// We do not directly use `InterpreterCreateQuery::execute`, because
/// - the database has not been loaded yet;
Expand Down

0 comments on commit 24e373a

Please sign in to comment.