diff --git a/cid/builtin/core/data/queries/co/auto_scale.json b/cid/builtin/core/data/queries/co/auto_scale.json index b7547aba..ef48f2f1 100644 --- a/cid/builtin/core/data/queries/co/auto_scale.json +++ b/cid/builtin/core/data/queries/co/auto_scale.json @@ -1,7 +1,7 @@ { "DatabaseName": "${athena_database_name}", "TableInput": { - "Name": "${athenaTableName}", + "Name": "${athena_table_name}", "StorageDescriptor": { "Location": "${s3FolderPath}", "Columns": [ diff --git a/cid/builtin/core/data/queries/co/ebs_volume.json b/cid/builtin/core/data/queries/co/ebs_volume.json index de38b944..0f1a107a 100644 --- a/cid/builtin/core/data/queries/co/ebs_volume.json +++ b/cid/builtin/core/data/queries/co/ebs_volume.json @@ -1,7 +1,7 @@ { "DatabaseName": "${athena_database_name}", "TableInput": { - "Name": "${athenaTableName}", + "Name": "${athena_table_name}", "StorageDescriptor": { "Location": "${s3FolderPath}", "Columns": [ diff --git a/cid/builtin/core/data/queries/co/ec2_instance.json b/cid/builtin/core/data/queries/co/ec2_instance.json index 0a35c64f..79c39f7d 100644 --- a/cid/builtin/core/data/queries/co/ec2_instance.json +++ b/cid/builtin/core/data/queries/co/ec2_instance.json @@ -1,7 +1,7 @@ { "DatabaseName": "${athena_database_name}", "TableInput": { - "Name": "${athenaTableName}", + "Name": "${athena_table_name}", "StorageDescriptor": { "Location": "${s3FolderPath}", "Columns": [ diff --git a/cid/builtin/core/data/queries/co/lambda.json b/cid/builtin/core/data/queries/co/lambda.json index 642e3d52..3622cf25 100644 --- a/cid/builtin/core/data/queries/co/lambda.json +++ b/cid/builtin/core/data/queries/co/lambda.json @@ -1,7 +1,7 @@ { "DatabaseName": "${athena_database_name}", "TableInput": { - "Name": "${athenaTableName}", + "Name": "${athena_table_name}", "StorageDescriptor": { "Location": "${s3FolderPath}", "Columns": [ diff --git a/cid/builtin/core/data/queries/co/rds_database.json b/cid/builtin/core/data/queries/co/rds_database.json index a1af388d..6bf3d944 100644 --- a/cid/builtin/core/data/queries/co/rds_database.json +++ b/cid/builtin/core/data/queries/co/rds_database.json @@ -1,7 +1,7 @@ { "DatabaseName": "${athena_database_name}", "TableInput": { - "Name": "${athenaTableName}", + "Name": "${athena_table_name}", "StorageDescriptor": { "Location": "${s3FolderPath}", "Columns": [ diff --git a/cid/builtin/core/data/queries/shared/cur.yaml b/cid/builtin/core/data/queries/shared/cur.yaml index e059aa52..fd4bb535 100644 --- a/cid/builtin/core/data/queries/shared/cur.yaml +++ b/cid/builtin/core/data/queries/shared/cur.yaml @@ -1,6 +1,6 @@ DatabaseName: "${athena_database_name}" TableInput: - Name: "${athenaTableName}" + Name: "${athena_table_name}" Owner: owner Retention: 0 TableType: EXTERNAL_TABLE diff --git a/cid/builtin/core/data/queries/tao/glue_table.json b/cid/builtin/core/data/queries/tao/glue_table.json index 46d7aff6..e3f4696c 100644 --- a/cid/builtin/core/data/queries/tao/glue_table.json +++ b/cid/builtin/core/data/queries/tao/glue_table.json @@ -1,7 +1,7 @@ { "DatabaseName": "${athena_database_name}", "TableInput": { - "Name": "${athenaTableName}", + "Name": "${athena_table_name}", "StorageDescriptor": { "Location": "${s3FolderPath}", "Columns": [ diff --git a/cid/common.py b/cid/common.py index 5e41585e..ca377c19 100644 --- a/cid/common.py +++ b/cid/common.py @@ -1741,6 +1741,7 @@ def get_view_query(self, view_name: str) -> str: columns_tpl = { #'athena_datasource_arn': athena_datasource.arn, 'athena_database_name': self.athena.DatabaseName, + 'athena_table_name': view_name, 'cur_database': self.cur1.database if cur1_required else None, # for backward compatibly 'cur_table_name': self.cur1.table_name if cur1_required else None, # for backward compatibly 'cur1_database': self.cur1.database if cur1_required else None,