Skip to content

Commit

Permalink
Update aws-marketplace-spg.yaml
Browse files Browse the repository at this point in the history
  • Loading branch information
iakov-aws authored Apr 11, 2024
1 parent 923893f commit b879e12
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions dashboards/aws-marketplace/aws-marketplace-spg.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,7 @@ views:
dependsOn:
cur: true
data: |-
CREATE OR REPLACE VIEW ${athena_database_name}.marketplace_view AS
CREATE OR REPLACE VIEW "${athena_database_name}"."marketplace_view" AS
SELECT
"year" "year"
, "month" "month"
Expand All @@ -165,6 +165,6 @@ views:
, "sum"((CASE WHEN ("line_item_line_item_type" = 'SavingsPlanCoveredUsage') THEN "line_item_usage_amount" WHEN ("line_item_line_item_type" = 'DiscountedUsage') THEN "line_item_usage_amount" WHEN ("line_item_line_item_type" = 'Usage') THEN "line_item_usage_amount" ELSE 0 END)) "usage_quantity"
, "sum"("line_item_unblended_cost") "unblended_cost"
FROM
${cur_table_name}
"${cur_table_name}"
WHERE ((("bill_billing_period_start_date" >= ("date_trunc"('month', current_timestamp) - INTERVAL '36' MONTH)) AND (CAST("concat"("year", '-', "month", '-01') AS date) >= ("date_trunc"('month', current_date) - INTERVAL '36' MONTH))) AND ("bill_billing_entity" = 'AWS Marketplace'))
GROUP BY 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21

0 comments on commit b879e12

Please sign in to comment.