diff --git a/docs-mslearn/toolkit/changelog.md b/docs-mslearn/toolkit/changelog.md index 01fb8c497..2e8d0e235 100644 --- a/docs-mslearn/toolkit/changelog.md +++ b/docs-mslearn/toolkit/changelog.md @@ -3,7 +3,7 @@ title: FinOps toolkit changelog description: Review the latest features and enhancements in the FinOps toolkit, including updates to FinOps hubs, Power BI reports, and more. author: MSBrett ms.author: brettwil -ms.date: 03/04/2026 +ms.date: 03/11/2026 ms.topic: reference ms.service: finops ms.subservice: finops-toolkit @@ -70,6 +70,11 @@ The following section lists features and enhancements that are currently in deve - Fixed inverted verbose logging in [Start-FinOpsCostExport](powershell/cost-management/Start-FinOpsCostExport.md) that showed blank dates when a date range was specified. - Addressed minor lint warnings across PowerShell commands. +### [Power BI reports](power-bi/reports.md) v14 + +- **Fixed** + - Paginate Azure Resource Graph queries by subscription to mitigate [payload size limit](help/errors.md#response-payload-size-is-and-has-exceeded-the-limit) errors in the [Governance](power-bi/governance.md) and [Workload optimization](power-bi/workload-optimization.md) reports ([#1768](https://github.com/microsoft/finops-toolkit/issues/1768)). +
## v13 Update 1 diff --git a/docs-mslearn/toolkit/help/errors.md b/docs-mslearn/toolkit/help/errors.md index c8bc43d5a..393c858ad 100644 --- a/docs-mslearn/toolkit/help/errors.md +++ b/docs-mslearn/toolkit/help/errors.md @@ -3,7 +3,7 @@ title: Troubleshoot common FinOps toolkit errors description: This article describes common FinOps toolkit errors and provides solutions to help you resolve issues you might encounter. author: flanakin ms.author: micflan -ms.date: 02/24/2026 +ms.date: 03/11/2026 ms.topic: troubleshooting ms.service: finops ms.subservice: finops-toolkit @@ -747,13 +747,59 @@ Azure Resource Graph queries in the Governance and Workload optimization Power B > _OLE DB or ODBC error: [Expression.Error] Please provide below info when asking for support: timestamp = {timestamp}, correlationId = {guid}. Details: Response payload size is {number}, and has exceeded the limit of 16777216. Please consider querying less data at a time and make paginated call if needed._ -This error means that you have more resources than are supported in an unfiltered Resource Graph query. This happens because FinOps toolkit reports are designed to show resource-level details and are not aggregated. They are designed for small- and medium-sized environments and not designed to support organizations with millions of resources. +Azure Resource Graph enforces a 16 MB response payload limit per query. FinOps toolkit reports automatically paginate queries in batches of subscriptions (default: 100 per batch) to stay within this limit, so most environments should not encounter this error. If you still see it, it means the resources in a single batch of subscriptions exceed the 16 MB limit. -**Mitigation**: If you experience this error, there are several options: +**Mitigation**: Try the following options in order: -- Remove columns that are not necessary for your needs. -- Filter the query to return fewer resources based on what's most important for you (e.g., subscriptions, tags). -- Disable the query so it doesn't block other queries from running. +### Option 1: Reduce the batch size + +Reduce the number of subscriptions queried in each batch: + +1. Open Power BI Desktop and select **Transform data** from the ribbon. +2. In the **Queries** pane on the left, expand the **Functions** folder. +3. Select the **ftk_ARGBatchSize** function. +4. Change the return value from `100` to a smaller number (e.g., `20` or `10`). +5. Select **Close & Apply** to save changes. + +### Option 2: Filter by resource group or tags + +Add a filter clause to the failing query to reduce the number of resources returned: + +1. Open Power BI Desktop and select **Transform data** from the ribbon. +2. In the **Queries** pane on the left, expand the **Resource Graph** folder. +3. Select the query that's failing (e.g., **NetworkSecurityGroups**, **Resources**). +4. In the query editor, find the `query = "` section in the formula bar. +5. Add a filter clause after the `| where type` line and before any `| extend` clauses. For example: + + ```kusto + | where resourceGroup in~ ('rg-production', 'rg-staging') + ``` + + Or filter by tags: + + ```kusto + | where tags.Environment =~ 'Production' + ``` + +6. Select **Close & Apply** to save changes. + +### Option 3: Remove unnecessary columns + +Reduce the payload size by removing columns you don't need: + +1. Open the query in Power Query Editor (steps 1-3 from Option 2). +2. In the query text, remove column names from the `extend` or `project` statements that you don't need for your analysis. +3. Be careful not to remove columns that are used in report visuals or relationships. + +### Option 4: Disable the failing query + +If a specific query consistently fails and isn't critical to your needs: + +1. In Power Query Editor, right-click the failing query in the **Queries** pane. +2. Uncheck **Enable load** to prevent the query from loading data. +3. The query will remain in the report but won't execute during refresh. + +For more information about Azure Resource Graph limits, see [Working with large Azure resource data sets](/azure/governance/resource-graph/concepts/work-with-data).
diff --git a/docs-mslearn/toolkit/power-bi/governance.md b/docs-mslearn/toolkit/power-bi/governance.md index db446af03..9a6456e72 100644 --- a/docs-mslearn/toolkit/power-bi/governance.md +++ b/docs-mslearn/toolkit/power-bi/governance.md @@ -3,7 +3,7 @@ title: FinOps toolkit Governance report description: Summarize cloud governance posture including areas like compliance, security, operations, and resource management in Power BI. author: flanakin ms.author: micflan -ms.date: 02/24/2026 +ms.date: 03/11/2026 ms.topic: concept-article ms.service: finops ms.subservice: finops-toolkit @@ -119,6 +119,14 @@ The **Network security groups** page lists network security groups and network s
+## Known limitations + +The Governance report uses Azure Resource Graph to query resource details. Azure Resource Graph has a response payload limit of 16 MB per query. The report automatically paginates queries in batches of subscriptions to stay within this limit, but may not work for large environments where a single batch exceeds the limit. + +If you experience a "Response payload size... exceeded the limit" error, open the report in Power BI Desktop, go to the Power Query editor, and reduce the value returned by the `ftk_ARGBatchSize` function (default: 100). For detailed steps, see [Response payload size exceeded the limit](../help/errors.md#response-payload-size-is-and-has-exceeded-the-limit) in the error reference guide. + +
+ ## Looking for more? We'd love to hear about any reports, charts, or general reporting questions you're looking to answer. Create a new issue with the details that you'd like to see either included in existing or new reports. diff --git a/docs-mslearn/toolkit/power-bi/workload-optimization.md b/docs-mslearn/toolkit/power-bi/workload-optimization.md index 228652c65..ab4d20abd 100644 --- a/docs-mslearn/toolkit/power-bi/workload-optimization.md +++ b/docs-mslearn/toolkit/power-bi/workload-optimization.md @@ -3,7 +3,7 @@ title: FinOps toolkit Workload optimization report description: Learn about the Workload optimization report, which identifies opportunities for rightsizing and removing unused resources to enhance efficiency. author: flanakin ms.author: micflan -ms.date: 02/24/2026 +ms.date: 03/11/2026 ms.topic: concept-article ms.service: finops ms.subservice: finops-toolkit @@ -79,10 +79,11 @@ The chart shows the cost of each disk over time. The table shows the disks with
-## See also +## Known limitations -- [Common terms](../help/terms.md) -- [Data dictionary](../help/data-dictionary.md) +The Workload optimization report uses Azure Resource Graph to query resource details. Azure Resource Graph has a response payload limit of 16 MB per query. The report automatically paginates queries in batches of subscriptions to stay within this limit, but may not work for large environments where a single batch exceeds the limit. + +If you experience a "Response payload size... exceeded the limit" error, open the report in Power BI Desktop, go to the Power Query editor, and reduce the value returned by the `ftk_ARGBatchSize` function (default: 100). For detailed steps, see [Response payload size exceeded the limit](../help/errors.md#response-payload-size-is-and-has-exceeded-the-limit) in the error reference guide.
@@ -99,6 +100,11 @@ We'd love to hear about any reports, charts, or general reporting questions you' ## Related content +Related resources: + +- [Common terms](../help/terms.md) +- [Data dictionary](../help/data-dictionary.md) + Related FinOps capabilities: - [Reporting and analytics](../../framework/understand/reporting.md) diff --git a/src/power-bi/kql/Shared.Dataset/definition/expressions.tmdl b/src/power-bi/kql/Shared.Dataset/definition/expressions.tmdl index 7094545d6..8901b80f8 100644 --- a/src/power-bi/kql/Shared.Dataset/definition/expressions.tmdl +++ b/src/power-bi/kql/Shared.Dataset/definition/expressions.tmdl @@ -89,6 +89,45 @@ expression ftk_DemoFilter = annotation PBI_ResultType = Function +/// Number of subscriptions to include in each Azure Resource Graph query batch. Decrease if you experience payload limit errors. Default: 100. +expression ftk_ARGBatchSize = () => 100 + lineageTag: f7a1b2c3-d4e5-6789-0abc-def123456789 + queryGroup: Functions + + annotation PBI_NavigationStepName = Navigation + + annotation PBI_ResultType = Function + +/// Queries Azure Resource Graph in batches of subscriptions and combines results to avoid the 16 MB payload limit. +expression ftk_QueryARG = + (query as text, optional batchMultiplier as number) => + let + batchSize = ftk_ARGBatchSize() * (if batchMultiplier <> null then batchMultiplier else 1), + subQuery = "resourcecontainers | where type == 'microsoft.resources/subscriptions' | project subscriptionId" & ftk_DemoFilter(), + Subscriptions = AzureResourceGraph.Query(subQuery, "Tenant", null, null, [resultTruncated = false]), + SubscriptionIds = Subscriptions[subscriptionId], + BatchCount = Number.RoundUp(List.Count(SubscriptionIds) / batchSize), + Batches = List.Transform({0..BatchCount-1}, each + let + batchStart = _ * batchSize, + batchIds = List.Range(SubscriptionIds, batchStart, List.Min({batchSize, List.Count(SubscriptionIds) - batchStart})), + subFilter = " | where subscriptionId in (" & Text.Combine(List.Transform(batchIds, each "'" & _ & "'"), ",") & ")", + fullQuery = query & subFilter, + Source = AzureResourceGraph.Query(fullQuery, "Tenant", null, null, [resultTruncated = false]) + in + if Table.HasColumns(Source, "Results") and Table.RowCount(Source) = 1 then null else Source + ), + Filtered = List.RemoveNulls(Batches), + Combined = if List.Count(Filtered) > 0 then Table.Combine(Filtered) else null + in + Combined + lineageTag: a1b2c3d4-e5f6-7890-abcd-ef1234567890 + queryGroup: Functions + + annotation PBI_NavigationStepName = Navigation + + annotation PBI_ResultType = Function + /// URI of the FinOps hub Azure Data Explorer cluster to pull data from. Copy from the "clusterUri" deployment output. /// /// Pro tip: As a shortcut, you can alternatively use the "{name}.{region}" subset of the URI. @@ -114,14 +153,15 @@ expression PolicyDefinitions = query = " policyResources | where type =='microsoft.authorization/policydefinitions' - | extend displayName = properties.displayName, + | extend + subscriptionId = tostring(split(id, '/')[2]), + displayName = properties.displayName, description = properties.description, version = properties.version - | project subscriptionId, id, name, displayName, description, version" - & ftk_DemoFilter(), - Source = AzureResourceGraph.Query(query, "Tenant", null, null, [resultTruncated = false]), + | project subscriptionId, id, name, displayName, description, version", + Source = ftk_QueryARG(query, 5), NullHandling = - if Table.HasColumns(Source, "Results") and Table.RowCount(Source) = 1 then + if Source = null then #table( { "subscriptionId", "id", "name", "displayName", "description", "version" }, {} diff --git a/src/power-bi/kql/Shared.Dataset/definition/tables/AdvisorRecommendations.tmdl b/src/power-bi/kql/Shared.Dataset/definition/tables/AdvisorRecommendations.tmdl index 3cd11b074..17706c3d6 100644 --- a/src/power-bi/kql/Shared.Dataset/definition/tables/AdvisorRecommendations.tmdl +++ b/src/power-bi/kql/Shared.Dataset/definition/tables/AdvisorRecommendations.tmdl @@ -475,10 +475,8 @@ table AdvisorRecommendations queryGroup: 'Resource Graph' source = ``` let - Source = AzureResourceGraph.Query(" - - - advisorresources + query = " + advisorresources | where type == 'microsoft.advisor/recommendations' | where properties.category == 'Cost' | extend @@ -523,11 +521,10 @@ table AdvisorRecommendations ['properties.resourceMetadata.action'] = properties.resourceMetadata.action, ['properties.resourceMetadata.source'] = properties.resourceMetadata.source, SortOrder = case(properties.impact == 'High', 1, properties.impact == 'Medium', 2, properties.impact == 'Low', 3, 9) - - - " & ftk_DemoFilter(), "Tenant", null, null, [resultTruncated = true]), + ", + Source = ftk_QueryARG(query, 5), NullHandling = - if Table.HasColumns(Source, "Results") and Table.RowCount(Source) = 1 then + if Source = null then #table( { "id", "name", "type", "properties.recommendationTypeId", "properties.shortDescription", "properties.resourceMetadata", "properties.suppressionIds", "properties.impactedField", "properties.impactedValue", "properties.lastUpdated", "properties.category", "properties.metadata", "properties.impact", "properties.shortDescription.problem", "properties.shortDescription.solution", "properties.extendedProperties.ObservationPeriodStartDate", "properties.extendedProperties.ObservationPeriodEndDate", "properties.extendedProperties.annualSavingsAmount", "properties.extendedProperties.HasRecommendation", "properties.extendedProperties.savingsCurrency", "properties.extendedProperties.IsInReplication", "properties.extendedProperties.Recommended_DTU", "properties.extendedProperties.Recommended_SKU", "properties.extendedProperties.ResourceGroup", "properties.extendedProperties.savingsAmount", "properties.extendedProperties.DatabaseSize", "properties.extendedProperties.DatabaseName", "properties.extendedProperties.ServerName", "properties.extendedProperties.Region", "properties.extendedProperties.lookbackPeriod", "properties.extendedProperties.subId", "properties.extendedProperties.scope", "properties.extendedProperties.term", "properties.extendedProperties.sku", "properties.extendedProperties.commitment", "properties.extendedProperties.currentSku", "properties.extendedProperties.targetSku", "properties.extendedProperties.recommendationMessage", "properties.resourceMetadata.resourceId", "properties.resourceMetadata.singular", "properties.resourceMetadata.plural", "properties.resourceMetadata.action", "properties.resourceMetadata.source", "SortOrder" }, {} diff --git a/src/power-bi/kql/Shared.Dataset/definition/tables/AdvisorReservationRecommendations.tmdl b/src/power-bi/kql/Shared.Dataset/definition/tables/AdvisorReservationRecommendations.tmdl index 394f7a2cf..af41378d3 100644 --- a/src/power-bi/kql/Shared.Dataset/definition/tables/AdvisorReservationRecommendations.tmdl +++ b/src/power-bi/kql/Shared.Dataset/definition/tables/AdvisorReservationRecommendations.tmdl @@ -298,6 +298,138 @@ table AdvisorReservationRecommendations annotation SummarizationSetBy = Automatic + column 'properties.extendedProperties.ObservationPeriodStartDate' + dataType: dateTime + formatString: General Date + lineageTag: 1e286848-dabb-4034-8913-cd9cf2144716 + summarizeBy: none + sourceColumn: properties.extendedProperties.ObservationPeriodStartDate + + annotation SummarizationSetBy = Automatic + + column 'properties.extendedProperties.ObservationPeriodEndDate' + dataType: dateTime + formatString: General Date + lineageTag: 55c1b862-e2f9-4655-aedc-1e5d5b02e2d4 + summarizeBy: none + sourceColumn: properties.extendedProperties.ObservationPeriodEndDate + + annotation SummarizationSetBy = Automatic + + column 'properties.extendedProperties.HasRecommendation' + dataType: string + lineageTag: b87c10ce-9453-41d4-b56b-680bae8ac4a2 + summarizeBy: none + sourceColumn: properties.extendedProperties.HasRecommendation + + annotation SummarizationSetBy = Automatic + + column 'properties.extendedProperties.IsInReplication' + dataType: string + lineageTag: 7a6be7dd-254a-45a5-8aba-3ca27eca2b5b + summarizeBy: none + sourceColumn: properties.extendedProperties.IsInReplication + + annotation SummarizationSetBy = Automatic + + column 'properties.extendedProperties.Recommended_DTU' + dataType: string + lineageTag: 48b988f9-4dc0-4f84-86a8-8c3b87940179 + summarizeBy: none + sourceColumn: properties.extendedProperties.Recommended_DTU + + annotation SummarizationSetBy = Automatic + + column 'properties.extendedProperties.Recommended_SKU' + dataType: string + lineageTag: 0a0fdca3-221d-4572-aed6-5c840358cb69 + summarizeBy: none + sourceColumn: properties.extendedProperties.Recommended_SKU + + annotation SummarizationSetBy = Automatic + + column 'properties.extendedProperties.ResourceGroup' + dataType: string + lineageTag: f5ffcebb-d130-457c-a298-6d462eea16bb + summarizeBy: none + sourceColumn: properties.extendedProperties.ResourceGroup + + annotation SummarizationSetBy = Automatic + + column 'properties.extendedProperties.DatabaseSize' + dataType: string + lineageTag: 42dffd26-268e-49a1-b047-99e8c0f7f104 + summarizeBy: none + sourceColumn: properties.extendedProperties.DatabaseSize + + annotation SummarizationSetBy = Automatic + + column 'properties.extendedProperties.DatabaseName' + dataType: string + lineageTag: f74bb29d-f74d-4c35-bc25-66818909cfcc + summarizeBy: none + sourceColumn: properties.extendedProperties.DatabaseName + + annotation SummarizationSetBy = Automatic + + column 'properties.extendedProperties.ServerName' + dataType: string + lineageTag: 804d5612-8c2e-4881-a80b-37968100ba21 + summarizeBy: none + sourceColumn: properties.extendedProperties.ServerName + + annotation SummarizationSetBy = Automatic + + column 'properties.extendedProperties.Region' + dataType: string + lineageTag: 68593266-9950-4caf-9522-ccfcbaa5d5e3 + summarizeBy: none + sourceColumn: properties.extendedProperties.Region + + annotation SummarizationSetBy = Automatic + + column 'properties.extendedProperties.commitment' + dataType: string + lineageTag: e0b87d0c-8c42-4354-b85a-5fc93d4af06a + summarizeBy: none + sourceColumn: properties.extendedProperties.commitment + + annotation SummarizationSetBy = Automatic + + column 'properties.extendedProperties.currentSku' + dataType: string + lineageTag: 11320610-15d3-4db1-89b5-746d92fbf0fa + summarizeBy: none + sourceColumn: properties.extendedProperties.currentSku + + annotation SummarizationSetBy = Automatic + + column 'properties.extendedProperties.targetSku' + dataType: string + lineageTag: 9a5c5a7c-8a59-4445-8946-d13f64fb3091 + summarizeBy: none + sourceColumn: properties.extendedProperties.targetSku + + annotation SummarizationSetBy = Automatic + + column 'properties.extendedProperties.recommendationMessage' + dataType: string + lineageTag: b2c1b5c3-ae28-4630-8823-d2db3604a1fb + summarizeBy: none + sourceColumn: properties.extendedProperties.recommendationMessage + + annotation SummarizationSetBy = Automatic + + column SortOrder + dataType: double + lineageTag: 0abaa4e9-cb2e-49bf-97ab-a0e6f54d3cb2 + summarizeBy: sum + sourceColumn: SortOrder + + annotation SummarizationSetBy = Automatic + + annotation PBI_FormatHint = {"isGeneralNumber":true} + partition AdvisorReservationRecommendations = m mode: import queryGroup: 'Resource Graph' @@ -306,8 +438,7 @@ table AdvisorReservationRecommendations query = " advisorresources | where type == 'microsoft.advisor/recommendations' - | where properties['category'] == 'Cost' - | where properties['shortDescription']['solution'] == 'Consider virtual machine reserved instance to save over your on-demand costs' + | where properties.category == 'Cost' | extend ['properties.recommendationTypeId'] = properties.recommendationTypeId, ['properties.shortDescription'] = properties.shortDescription, @@ -321,12 +452,23 @@ table AdvisorReservationRecommendations ['properties.impact'] = properties.impact, ['properties.shortDescription.problem'] = properties.shortDescription.problem, ['properties.shortDescription.solution'] = properties.shortDescription.solution, + ['properties.extendedProperties.ObservationPeriodStartDate'] = properties.extendedProperties.ObservationPeriodStartDate, + ['properties.extendedProperties.ObservationPeriodEndDate'] = properties.extendedProperties.ObservationPeriodEndDate, ['properties.extendedProperties.reservedResourceType'] = properties.extendedProperties.reservedResourceType, - ['properties.extendedProperties.annualSavingsAmount'] = properties.extendedProperties.annualSavingsAmount, + ['properties.extendedProperties.annualSavingsAmount'] = coalesce(properties.extendedProperties.annualSavingsAmount, 0), ['properties.extendedProperties.targetResourceCount'] = toint(properties.extendedProperties.targetResourceCount), + ['properties.extendedProperties.HasRecommendation'] = properties.extendedProperties.HasRecommendation, ['properties.extendedProperties.savingsCurrency'] = properties.extendedProperties.savingsCurrency, + ['properties.extendedProperties.IsInReplication'] = properties.extendedProperties.IsInReplication, + ['properties.extendedProperties.Recommended_DTU'] = properties.extendedProperties.Recommended_DTU, + ['properties.extendedProperties.Recommended_SKU'] = properties.extendedProperties.Recommended_SKU, + ['properties.extendedProperties.ResourceGroup'] = tolower(properties.extendedProperties.ResourceGroup), ['properties.extendedProperties.lookbackPeriod'] = properties.extendedProperties.lookbackPeriod, - ['properties.extendedProperties.savingsAmount'] = properties.extendedProperties.savingsAmount, + ['properties.extendedProperties.savingsAmount'] = coalesce(properties.extendedProperties.savingsAmount, 0), + ['properties.extendedProperties.DatabaseSize'] = properties.extendedProperties.DatabaseSize, + ['properties.extendedProperties.DatabaseName'] = properties.extendedProperties.DatabaseName, + ['properties.extendedProperties.ServerName'] = properties.extendedProperties.ServerName, + ['properties.extendedProperties.Region'] = properties.extendedProperties.Region, ['properties.extendedProperties.displaySKU'] = properties.extendedProperties.displaySKU, ['properties.extendedProperties.displayQty'] = toint(properties.extendedProperties.displayQty), ['properties.extendedProperties.location'] = properties.extendedProperties.location, @@ -337,21 +479,24 @@ table AdvisorReservationRecommendations ['properties.extendedProperties.term'] = properties.extendedProperties.term, ['properties.extendedProperties.sku'] = properties.extendedProperties.sku, ['properties.extendedProperties.qty'] = toint(properties.extendedProperties.qty), + ['properties.extendedProperties.commitment'] = properties.extendedProperties.commitment, + ['properties.extendedProperties.currentSku'] = properties.extendedProperties.currentSku, + ['properties.extendedProperties.targetSku'] = properties.extendedProperties.targetSku, + ['properties.extendedProperties.recommendationMessage'] = properties.extendedProperties.recommendationMessage, ['properties.resourceMetadata.resourceId'] = tolower(properties.resourceMetadata.resourceId), ['properties.resourceMetadata.singular'] = properties.resourceMetadata.singular, ['properties.resourceMetadata.plural'] = properties.resourceMetadata.plural, ['properties.resourceMetadata.action'] = properties.resourceMetadata.action, ['properties.resourceMetadata.source'] = properties.resourceMetadata.source, - recommendedActions = strcat(properties.extendedProperties.displaySKU, ' virtual machines in ', properties.extendedProperties.location), + recommendedActions = iff(isnotempty(properties.extendedProperties.displaySKU), strcat(properties.extendedProperties.displaySKU, ' virtual machines in ', properties.extendedProperties.location), tostring(properties.shortDescription.solution)), SortOrder = case(properties.impact == 'High', 1, properties.impact == 'Medium', 2, properties.impact == 'Low', 3, 9) | order by SortOrder asc - | project-away SortOrder - " & ftk_DemoFilter(), - Source = AzureResourceGraph.Query(query, "Tenant", null, null, [resultTruncated = false]), + ", + Source = ftk_QueryARG(query, 5), NullHandling = - if Table.HasColumns(Source, "Results") and Table.RowCount(Source) = 1 then + if Source = null then #table( - { "id", "name", "properties.recommendationTypeId", "properties.shortDescription", "properties.resourceMetadata", "properties.suppressionIds", "properties.impactedField", "properties.impactedValue", "properties.lastUpdated", "properties.category", "properties.metadata", "properties.impact", "properties.shortDescription.problem", "properties.shortDescription.solution", "properties.extendedProperties.reservedResourceType", "properties.extendedProperties.annualSavingsAmount", "properties.extendedProperties.targetResourceCount", "properties.extendedProperties.savingsCurrency", "properties.extendedProperties.lookbackPeriod", "properties.extendedProperties.savingsAmount", "properties.extendedProperties.displaySKU", "properties.extendedProperties.displayQty", "properties.extendedProperties.location", "properties.extendedProperties.region", "properties.extendedProperties.vmSize", "properties.extendedProperties.subId", "properties.extendedProperties.scope", "properties.extendedProperties.term", "properties.extendedProperties.sku", "properties.extendedProperties.qty", "properties.resourceMetadata.resourceId", "properties.resourceMetadata.singular", "properties.resourceMetadata.plural", "properties.resourceMetadata.action", "properties.resourceMetadata.source", "recommendedActions" }, + { "id", "name", "properties.recommendationTypeId", "properties.shortDescription", "properties.resourceMetadata", "properties.suppressionIds", "properties.impactedField", "properties.impactedValue", "properties.lastUpdated", "properties.category", "properties.metadata", "properties.impact", "properties.shortDescription.problem", "properties.shortDescription.solution", "properties.extendedProperties.ObservationPeriodStartDate", "properties.extendedProperties.ObservationPeriodEndDate", "properties.extendedProperties.reservedResourceType", "properties.extendedProperties.annualSavingsAmount", "properties.extendedProperties.targetResourceCount", "properties.extendedProperties.HasRecommendation", "properties.extendedProperties.savingsCurrency", "properties.extendedProperties.IsInReplication", "properties.extendedProperties.Recommended_DTU", "properties.extendedProperties.Recommended_SKU", "properties.extendedProperties.ResourceGroup", "properties.extendedProperties.lookbackPeriod", "properties.extendedProperties.savingsAmount", "properties.extendedProperties.DatabaseSize", "properties.extendedProperties.DatabaseName", "properties.extendedProperties.ServerName", "properties.extendedProperties.Region", "properties.extendedProperties.displaySKU", "properties.extendedProperties.displayQty", "properties.extendedProperties.location", "properties.extendedProperties.region", "properties.extendedProperties.vmSize", "properties.extendedProperties.subId", "properties.extendedProperties.scope", "properties.extendedProperties.term", "properties.extendedProperties.sku", "properties.extendedProperties.qty", "properties.extendedProperties.commitment", "properties.extendedProperties.currentSku", "properties.extendedProperties.targetSku", "properties.extendedProperties.recommendationMessage", "properties.resourceMetadata.resourceId", "properties.resourceMetadata.singular", "properties.resourceMetadata.plural", "properties.resourceMetadata.action", "properties.resourceMetadata.source", "recommendedActions", "SortOrder" }, {} ) else Source, @@ -360,14 +505,15 @@ table AdvisorReservationRecommendations {"properties.extendedProperties.savingsAmount", type number}, {"properties.extendedProperties.qty", Int64.Type}, {"properties.extendedProperties.displayQty", Int64.Type}, - {"properties.extendedProperties.lookbackPeriod", Int64.Type}, {"properties.extendedProperties.targetResourceCount", Int64.Type}, + {"SortOrder", type number}, + {"properties.extendedProperties.ObservationPeriodStartDate", type datetimezone}, + {"properties.extendedProperties.ObservationPeriodEndDate", type datetimezone}, {"properties.lastUpdated", type datetimezone} - }) + }, "en-US") in Types annotation PBI_NavigationStepName = Navigation annotation PBI_ResultType = Table - diff --git a/src/power-bi/kql/Shared.Dataset/definition/tables/Disks.tmdl b/src/power-bi/kql/Shared.Dataset/definition/tables/Disks.tmdl index 076817722..f4ac4134a 100644 --- a/src/power-bi/kql/Shared.Dataset/definition/tables/Disks.tmdl +++ b/src/power-bi/kql/Shared.Dataset/definition/tables/Disks.tmdl @@ -203,10 +203,10 @@ table Disks Redundancy, parentVM, diskType - " & ftk_DemoFilter(), - Source = AzureResourceGraph.Query(query, "Tenant", null, null, [resultTruncated = false]), + ", + Source = ftk_QueryARG(query, 2), NullHandling = - if Table.HasColumns(Source, "Results") and Table.RowCount(Source) = 1 then + if Source = null then #table( { "id", "name", "subscriptionId", "resourceGroup", "tenantId", "location", "managedBy", "osType", "skuName", "skuTier", "diskSizeGB", "diskMBpsReadWrite", "diskIOPSReadWrite", "diskState", "timeCreated", "LastOwnershipUpdateTime", "Redundancy", "parentVM", "diskType" }, {} diff --git a/src/power-bi/kql/Shared.Dataset/definition/tables/NetworkInterfaces.tmdl b/src/power-bi/kql/Shared.Dataset/definition/tables/NetworkInterfaces.tmdl index b686649d9..3e5770345 100644 --- a/src/power-bi/kql/Shared.Dataset/definition/tables/NetworkInterfaces.tmdl +++ b/src/power-bi/kql/Shared.Dataset/definition/tables/NetworkInterfaces.tmdl @@ -437,10 +437,10 @@ table NetworkInterfaces ['properties.ipConfigurations.properties.publicIPAddress'] = properties.ipConfigurations.properties.publicIPAddress, ['properties.ipConfigurations.properties.publicIPAddress.id'] = properties.ipConfigurations.properties.publicIPAddress.id, ['properties.networkSecurityGroup.id'] = properties.networkSecurityGroup.id - " & ftk_DemoFilter(), - Source = AzureResourceGraph.Query(query, "Tenant", null, null, [resultTruncated = false]), + ", + Source = ftk_QueryARG(query, 2), NullHandling = - if Table.HasColumns(Source, "Results") and Table.RowCount(Source) = 1 then + if Source = null then #table( { "id", "name", "location", "resourceGroup", "properties.provisioningState", "properties.resourceGuid", "properties.enableAcceleratedNetworking", "properties.disableTcpStateTracking", "properties.vnetEncryptionSupported", "properties.networkSecurityGroup", "properties.ipConfigurations", "properties.enableIPForwarding", "properties.tapConfigurations", "properties.hostedWorkloads", "properties.allowPort25Out", "properties.auxiliaryMode", "properties.dnsSettings", "properties.auxiliarySku", "properties.macAddress", "properties.nicType", "properties.primary", "properties.virtualMachine", "properties.virtualMachine.id", "properties.ipConfigurations.type", "properties.ipConfigurations.name", "properties.ipConfigurations.properties", "properties.ipConfigurations.id", "properties.ipConfigurations.etag", "properties.ipConfigurations.properties.provisioningState", "properties.ipConfigurations.properties.privateIPAddressVersion", "properties.ipConfigurations.properties.privateIPAllocationMethod", "properties.ipConfigurations.properties.subnet", "properties.ipConfigurations.properties.privateIPAddress", "properties.ipConfigurations.properties.primary", "properties.ipConfigurations.properties.publicIPAddress", "properties.ipConfigurations.properties.publicIPAddress.id", "properties.networkSecurityGroup.id" }, {} diff --git a/src/power-bi/kql/Shared.Dataset/definition/tables/NetworkSecurityGroups.tmdl b/src/power-bi/kql/Shared.Dataset/definition/tables/NetworkSecurityGroups.tmdl index 130a15a78..82509f220 100644 --- a/src/power-bi/kql/Shared.Dataset/definition/tables/NetworkSecurityGroups.tmdl +++ b/src/power-bi/kql/Shared.Dataset/definition/tables/NetworkSecurityGroups.tmdl @@ -264,10 +264,10 @@ table NetworkSecurityGroups ['properties.securityRules.properties.direction'] = properties.securityRules.properties.direction, ['properties.securityRules.properties.priority'] = properties.securityRules.properties.priority, ['properties.securityRules.properties.access'] = properties.securityRules.properties.access - " & ftk_DemoFilter(), - Source = AzureResourceGraph.Query(query, "Tenant", null, null, [resultTruncated = false]), + ", + Source = ftk_QueryARG(query, 20), NullHandling = - if Table.HasColumns(Source, "Results") and Table.RowCount(Source) = 1 then + if Source = null then #table( { "id", "name", "location", "resourceGroup", "properties.resourceGuid", "properties.securityRules", "properties.securityRules.name", "properties.securityRules.id", "properties.securityRules.properties.destinationAddressPrefix", "properties.securityRules.properties.sourceAddressPrefix", "properties.securityRules.properties.destinationPortRange", "properties.securityRules.properties.sourcePortRange", "properties.securityRules.properties.protocol", "properties.securityRules.properties.direction", "properties.securityRules.properties.priority", "properties.securityRules.properties.access" }, {} diff --git a/src/power-bi/kql/Shared.Dataset/definition/tables/PolicyAssignments.tmdl b/src/power-bi/kql/Shared.Dataset/definition/tables/PolicyAssignments.tmdl index f2158a3ee..9723ccfab 100644 --- a/src/power-bi/kql/Shared.Dataset/definition/tables/PolicyAssignments.tmdl +++ b/src/power-bi/kql/Shared.Dataset/definition/tables/PolicyAssignments.tmdl @@ -369,6 +369,7 @@ table PolicyAssignments query = " policyResources | where type =~'Microsoft.Authorization/PolicyAssignments' + | extend subscriptionId = tostring(split(id, '/')[2]) | extend ['properties.policyDefinitionId'] = properties.policyDefinitionId, ['properties.effectiveDefinitionVersion'] = properties.effectiveDefinitionVersion, @@ -400,10 +401,10 @@ table PolicyAssignments ['identity.tenantId'] = identity.tenantId, ['identity.type'] = identity.type | mv-expand ['properties.notScopes'] - " & ftk_DemoFilter(), - Source = AzureResourceGraph.Query(query, "Tenant", null, null, [resultTruncated = false]), + ", + Source = ftk_QueryARG(query, 2), NullHandling = - if Table.HasColumns(Source, "Results") and Table.RowCount(Source) = 1 then + if Source = null then #table( { "id", "name", "location", "resourceGroup", "properties.policyDefinitionId", "properties.effectiveDefinitionVersion", "properties.latestDefinitionVersion", "properties.nonComplianceMessages", "properties.definitionVersion", "properties.resourceSelectors", "properties.enforcementMode", "properties.assignmentType", "properties.description", "properties.displayName", "properties.parameters", "properties.notScopes", "properties.overrides", "properties.metadata", "properties.scope", "properties.metadata.createdOn", "properties.metadata.createdBy", "properties.metadata.assignedBy", "properties.metadata.parameterScopes", "properties.metadata.updatedOn", "properties.metadata.updatedBy", "properties.metadata.category", "properties.metadata.managedByResourceId", "properties.metadata.securityCenter", "properties.metadata.excludedOutOfTheBoxStandards", "identity.userAssignedIdentities", "identity.principalId", "identity.tenantId", "identity.type" }, {} diff --git a/src/power-bi/kql/Shared.Dataset/definition/tables/PolicyStates.tmdl b/src/power-bi/kql/Shared.Dataset/definition/tables/PolicyStates.tmdl index 96ca590a7..13fa7c4c0 100644 --- a/src/power-bi/kql/Shared.Dataset/definition/tables/PolicyStates.tmdl +++ b/src/power-bi/kql/Shared.Dataset/definition/tables/PolicyStates.tmdl @@ -344,6 +344,7 @@ table PolicyStates query = " policyResources | where type =~'Microsoft.PolicyInsights/PolicyStates' + | extend subscriptionId = tostring(split(id, '/')[2]) | extend ['properties.policyAssignmentParameters'] = properties.policyAssignmentParameters, ['properties.policyDefinitionAction'] = properties.policyDefinitionAction, @@ -369,10 +370,10 @@ table PolicyStates ['properties.policyDefinitionGroupNames'] = properties.policyDefinitionGroupNames, ['properties.complianceReasonCode'] = properties.complianceReasonCode, ['properties.stateDetails'] = properties.stateDetails - " & ftk_DemoFilter(), - Source = AzureResourceGraph.Query(query, "Tenant", null, null, [resultTruncated = false]), + ", + Source = ftk_QueryARG(query, 2), NullHandling = - if Table.HasColumns(Source, "Results") and Table.RowCount(Source) = 1 then + if Source = null then #table( { "id", "name", "location", "resourceGroup", "properties.policyAssignmentParameters", "properties.policyDefinitionAction", "properties.policyAssignmentScope", "properties.policyAssignmentName", "properties.policyDefinitionName", "properties.policyDefinitionReferenceId", "properties.policyDefinitionId", "properties.managementGroupIds", "properties.policyAssignmentId", "properties.policySetDefinitionName", "properties.complianceState", "properties.policySetDefinitionId", "properties.subscriptionId", "properties.resourceType", "properties.stateWeight", "properties.resourceGroup", "properties.resourceId", "properties.timestamp", "properties.isDeleted", "properties.resourceLocation", "properties.policySetDefinitionCategory", "properties.policyDefinitionGroupNames", "properties.complianceReasonCode", "properties.stateDetails" }, {} diff --git a/src/power-bi/kql/Shared.Dataset/definition/tables/PublicIPAddresses.tmdl b/src/power-bi/kql/Shared.Dataset/definition/tables/PublicIPAddresses.tmdl index 02001da39..86bcd5aa8 100644 --- a/src/power-bi/kql/Shared.Dataset/definition/tables/PublicIPAddresses.tmdl +++ b/src/power-bi/kql/Shared.Dataset/definition/tables/PublicIPAddresses.tmdl @@ -210,10 +210,10 @@ table PublicIPAddresses ['properties.ipAddress'] = properties.ipAddress, ['properties.ipConfiguration'] = properties.ipConfiguration, ['properties.ipTags'] = properties.ipTags - " & ftk_DemoFilter(), - Source = AzureResourceGraph.Query(query, "Tenant", null, null, [resultTruncated = false]), + ", + Source = ftk_QueryARG(query, 5), NullHandling = - if Table.HasColumns(Source, "Results") and Table.RowCount(Source) = 1 then + if Source = null then #table( { "id", "name", "location", "resourceGroup", "properties.provisioningState", "properties.resourceGuid", "properties.idleTimeoutInMinutes", "properties.publicIPAllocationMethod", "properties.publicIPAddressVersion", "properties.ipAddress", "properties.ipConfiguration", "properties.ipTags" }, {} diff --git a/src/power-bi/kql/Shared.Dataset/definition/tables/Resources.tmdl b/src/power-bi/kql/Shared.Dataset/definition/tables/Resources.tmdl index 920ac471e..7fb4b5320 100644 --- a/src/power-bi/kql/Shared.Dataset/definition/tables/Resources.tmdl +++ b/src/power-bi/kql/Shared.Dataset/definition/tables/Resources.tmdl @@ -91,10 +91,10 @@ table Resources ['creationTime'] = properties.creationTime, ['timeModified'] = properties.timeModified | project id, name, type, tenantId, location, subscriptionId, resourceGroup, creationTime, timeModified - " & ftk_DemoFilter(), - Source = AzureResourceGraph.Query(query, "Tenant", null, null, [resultTruncated = false]), + ", + Source = ftk_QueryARG(query), NullHandling = - if Table.HasColumns(Source, "Results") and Table.RowCount(Source) = 1 then + if Source = null then #table( { "id", "name", "type", "tenantId", "location", "subscriptionId", "resourceGroup", "creationTime", "timeModified" }, {} diff --git a/src/power-bi/kql/Shared.Dataset/definition/tables/SqlDatabases.tmdl b/src/power-bi/kql/Shared.Dataset/definition/tables/SqlDatabases.tmdl index 58b6a81dd..5e2a64251 100644 --- a/src/power-bi/kql/Shared.Dataset/definition/tables/SqlDatabases.tmdl +++ b/src/power-bi/kql/Shared.Dataset/definition/tables/SqlDatabases.tmdl @@ -364,10 +364,10 @@ table SqlDatabases ['properties.currentSku'] = properties.currentSku, ['properties.readScale'] = properties.readScale, ['properties.maxLogSizeBytes'] = properties.maxLogSizeBytes - " & ftk_DemoFilter(), - Source = AzureResourceGraph.Query(query, "Tenant", null, null, [resultTruncated = false]), + ", + Source = ftk_QueryARG(query, 5), NullHandling = - if Table.HasColumns(Source, "Results") and Table.RowCount(Source) = 1 then + if Source = null then #table( { "id", "name", "sku.name", "sku.tier", "sku.capacity", "sku.family", "location", "resourceGroup", "properties.status", "properties.requestedBackupStorageRedundancy", "properties.currentBackupStorageRedundancy", "properties.requestedServiceObjectiveName", "properties.currentServiceObjectiveName", "properties.maintenanceConfigurationId", "properties.defaultSecondaryLocation", "properties.isInfraEncryptionEnabled", "properties.earliestRestoreDate", "properties.zoneRedundant", "properties.availabilityZone", "properties.catalogCollation", "properties.creationDate", "properties.collation", "properties.licenseType", "properties.maxSizeBytes", "properties.isLedgerOn", "properties.databaseId", "properties.currentSku", "properties.readScale", "properties.maxLogSizeBytes" }, {} diff --git a/src/power-bi/kql/Shared.Dataset/definition/tables/VirtualMachines.tmdl b/src/power-bi/kql/Shared.Dataset/definition/tables/VirtualMachines.tmdl index ad89d28af..2088d6a9d 100644 --- a/src/power-bi/kql/Shared.Dataset/definition/tables/VirtualMachines.tmdl +++ b/src/power-bi/kql/Shared.Dataset/definition/tables/VirtualMachines.tmdl @@ -614,10 +614,10 @@ table VirtualMachines | extend ['powerState.displayStatus'] = powerState.displayStatus | mv-expand ['zones'] - " & ftk_DemoFilter(), - Source = AzureResourceGraph.Query(query, "Tenant", null, null, [resultTruncated = false]), + ", + Source = ftk_QueryARG(query, 5), NullHandling = - if Table.HasColumns(Source, "Results") and Table.RowCount(Source) = 1 then + if Source = null then #table( { "id", "name", "location", "resourceGroup", "provisioningState", "timeCreated", "networkProfile", "osProfile", "storageProfile", "hardwareProfile", "vmId", "diagnosticsProfile", "extended", "licenseType", "osProfile.computerName", "osProfile.requireGuestProvisionSignal", "osProfile.allowExtensionOperations", "osProfile.adminUsername", "osProfile.secrets", "osProfile.linuxConfiguration", "osProfile.windowsConfiguration", "networkInterfaces", "networkInterfaces.properties", "networkInterfaces.id", "networkInterfaces.properties.deleteOption", "storageProfile.imageReference", "storageProfile.dataDisks", "storageProfile.osDisk", "storageProfile.imageReference.publisher", "storageProfile.imageReference.sku", "storageProfile.imageReference.version", "storageProfile.imageReference.exactVersion", "storageProfile.imageReference.offer", "storageProfile.dataDisks.name", "storageProfile.dataDisks.createOption", "storageProfile.dataDisks.deleteOption", "storageProfile.dataDisks.managedDisk", "storageProfile.dataDisks.caching", "storageProfile.dataDisks.toBeDetached", "storageProfile.dataDisks.writeAcceleratorEnabled", "storageProfile.dataDisks.lun", "storageProfile.dataDisks.managedDisk.id", "storageProfile.osDisk.name", "storageProfile.osDisk.createOption", "storageProfile.osDisk.osType", "storageProfile.osDisk.deleteOption", "storageProfile.osDisk.managedDisk", "storageProfile.osDisk.caching", "storageProfile.osDisk.managedDisk.id", "hardwareProfile.vmSize", "diagnosticsProfile.bootDiagnostics", "diagnosticsProfile.bootDiagnostics.enabled", "diagnosticsProfile.bootDiagnostics.storageUri", "instanceView", "powerState", "powerState.displayStatus" }, {} diff --git a/src/power-bi/storage/Shared.Dataset/definition/expressions.tmdl b/src/power-bi/storage/Shared.Dataset/definition/expressions.tmdl index 69c6f549c..1b5000e61 100644 --- a/src/power-bi/storage/Shared.Dataset/definition/expressions.tmdl +++ b/src/power-bi/storage/Shared.Dataset/definition/expressions.tmdl @@ -496,8 +496,47 @@ expression ftk_DemoFilter = annotation PBI_ResultType = Function +/// Number of subscriptions to include in each Azure Resource Graph query batch. Decrease if you experience payload limit errors. Default: 100. +expression ftk_ARGBatchSize = () => 100 + lineageTag: f7a1b2c3-d4e5-6789-0abc-def123456790 + queryGroup: Functions + + annotation PBI_NavigationStepName = Navigation + + annotation PBI_ResultType = Function + +/// Queries Azure Resource Graph in batches of subscriptions and combines results to avoid the 16 MB payload limit. +expression ftk_QueryARG = + (query as text, optional batchMultiplier as number) => + let + batchSize = ftk_ARGBatchSize() * (if batchMultiplier <> null then batchMultiplier else 1), + subQuery = "resourcecontainers | where type == 'microsoft.resources/subscriptions' | project subscriptionId" & ftk_DemoFilter(), + Subscriptions = AzureResourceGraph.Query(subQuery, "Tenant", null, null, [resultTruncated = false]), + SubscriptionIds = Subscriptions[subscriptionId], + BatchCount = Number.RoundUp(List.Count(SubscriptionIds) / batchSize), + Batches = List.Transform({0..BatchCount-1}, each + let + batchStart = _ * batchSize, + batchIds = List.Range(SubscriptionIds, batchStart, List.Min({batchSize, List.Count(SubscriptionIds) - batchStart})), + subFilter = " | where subscriptionId in (" & Text.Combine(List.Transform(batchIds, each "'" & _ & "'"), ",") & ")", + fullQuery = query & subFilter, + Source = AzureResourceGraph.Query(fullQuery, "Tenant", null, null, [resultTruncated = false]) + in + if Table.HasColumns(Source, "Results") and Table.RowCount(Source) = 1 then null else Source + ), + Filtered = List.RemoveNulls(Batches), + Combined = if List.Count(Filtered) > 0 then Table.Combine(Filtered) else null + in + Combined + lineageTag: a1b2c3d4-e5f6-7890-abcd-ef1234567891 + queryGroup: Functions + + annotation PBI_NavigationStepName = Navigation + + annotation PBI_ResultType = Function + /// Optional. Experimental feature to join the prices with the cost to populate missing list and contracted unit price and calculate missing cost values. This enables calculating total savings. Allowed values = "TRUE", "FALSE". -/// +/// /// This experimental feature is extremely slow to run and has not been fully tested. We are investigating alternative means to perform this join. expression 'Deprecated: Perform Extra Query Optimizations' = false meta [IsParameterQuery=true, List={false, true}, DefaultValue=false, Type="Logical", IsParameterQueryRequired=false] lineageTag: f22de62e-d0a2-4f18-be6a-86172ff55b17 @@ -520,15 +559,16 @@ expression PolicyDefinitions = let query = " policyResources - | where type =='microsoft.authorization/policydefinitions' | - extend displayName = properties.displayName, - description = properties.description, - version = properties.version - | project subscriptionId, id, name, displayName, description, version" - & ftk_DemoFilter(), - Source = AzureResourceGraph.Query(query, "Tenant", null, null, [resultTruncated = false]), + | where type =='microsoft.authorization/policydefinitions' + | extend + subscriptionId = tostring(split(id, '/')[2]), + displayName = properties.displayName, + description = properties.description, + version = properties.version + | project subscriptionId, id, name, displayName, description, version", + Source = ftk_QueryARG(query, 5), NullHandling = - if Table.HasColumns(Source, "Results") and Table.RowCount(Source) = 1 then + if Source = null then #table( { "subscriptionId", "id", "name", "displayName", "description", "version" }, {} diff --git a/src/power-bi/storage/Shared.Dataset/definition/tables/AdvisorRecommendations.tmdl b/src/power-bi/storage/Shared.Dataset/definition/tables/AdvisorRecommendations.tmdl deleted file mode 100644 index 922e08ebe..000000000 --- a/src/power-bi/storage/Shared.Dataset/definition/tables/AdvisorRecommendations.tmdl +++ /dev/null @@ -1,549 +0,0 @@ -table AdvisorRecommendations - lineageTag: a76a7ba9-b6b5-4140-9739-344b958bfc9f - - column id - dataType: string - lineageTag: de03600f-0938-479c-9668-1386cd8fd8cc - summarizeBy: none - sourceColumn: id - - annotation SummarizationSetBy = Automatic - - column name - dataType: string - lineageTag: b82b2171-5f91-421e-9052-b72ae63ed3c3 - summarizeBy: none - sourceColumn: name - - annotation SummarizationSetBy = Automatic - - column 'properties.recommendationTypeId' - dataType: string - lineageTag: b5215814-f868-4a8c-8c85-719e04a93cdd - summarizeBy: none - sourceColumn: properties.recommendationTypeId - - annotation SummarizationSetBy = Automatic - - column 'properties.extendedProperties.ObservationPeriodStartDate' - dataType: dateTime - formatString: General Date - lineageTag: ab4f38d6-4047-479b-9f9b-e410f75ddc7e - summarizeBy: none - sourceColumn: properties.extendedProperties.ObservationPeriodStartDate - - annotation SummarizationSetBy = Automatic - - column 'properties.extendedProperties.ObservationPeriodEndDate' - dataType: dateTime - formatString: General Date - lineageTag: 56c63f3b-8ddd-4c48-a1d4-ebd95bb7c077 - summarizeBy: none - sourceColumn: properties.extendedProperties.ObservationPeriodEndDate - - annotation SummarizationSetBy = Automatic - - column 'properties.extendedProperties.annualSavingsAmount' - dataType: double - lineageTag: 19b8e57a-5d4c-47c6-b339-244398d3280f - summarizeBy: sum - sourceColumn: properties.extendedProperties.annualSavingsAmount - - annotation SummarizationSetBy = Automatic - - annotation PBI_FormatHint = {"isGeneralNumber":true} - - column 'properties.extendedProperties.HasRecommendation' - dataType: string - lineageTag: 43a90524-510a-48a1-a41b-67275ab5a220 - summarizeBy: none - sourceColumn: properties.extendedProperties.HasRecommendation - - annotation SummarizationSetBy = Automatic - - column 'properties.extendedProperties.savingsCurrency' - dataType: string - lineageTag: 17b12b2b-14c2-4a12-90d0-1faa1b3a192b - summarizeBy: none - sourceColumn: properties.extendedProperties.savingsCurrency - - annotation SummarizationSetBy = Automatic - - column 'properties.extendedProperties.IsInReplication' - dataType: string - lineageTag: dbfe3e6c-c999-447a-bc1b-c7fe0e506013 - summarizeBy: none - sourceColumn: properties.extendedProperties.IsInReplication - - annotation SummarizationSetBy = Automatic - - column 'properties.extendedProperties.Recommended_DTU' - dataType: string - lineageTag: a7158037-adc3-42fb-a6ee-234086f5dc36 - summarizeBy: none - sourceColumn: properties.extendedProperties.Recommended_DTU - - annotation SummarizationSetBy = Automatic - - column 'properties.extendedProperties.Recommended_SKU' - dataType: string - lineageTag: 73678d68-9152-45dc-b63b-c84bec6430c3 - summarizeBy: none - sourceColumn: properties.extendedProperties.Recommended_SKU - - annotation SummarizationSetBy = Automatic - - column 'properties.extendedProperties.ResourceGroup' - dataType: string - lineageTag: b96cc7fb-e6a6-456c-b1a7-62a7f1faf6f2 - summarizeBy: none - sourceColumn: properties.extendedProperties.ResourceGroup - - annotation SummarizationSetBy = Automatic - - column 'properties.extendedProperties.DatabaseSize' - dataType: string - lineageTag: 291bcdda-5321-4bb3-8900-62cb86a30af8 - summarizeBy: none - sourceColumn: properties.extendedProperties.DatabaseSize - - annotation SummarizationSetBy = Automatic - - column 'properties.extendedProperties.DatabaseName' - dataType: string - lineageTag: 282b6040-b89c-4139-95bf-c914e6a07138 - summarizeBy: none - sourceColumn: properties.extendedProperties.DatabaseName - - annotation SummarizationSetBy = Automatic - - column 'properties.extendedProperties.ServerName' - dataType: string - lineageTag: 64d82cc4-f542-4ee4-9cdd-f0ce960d97a4 - summarizeBy: none - sourceColumn: properties.extendedProperties.ServerName - - annotation SummarizationSetBy = Automatic - - column 'properties.extendedProperties.Region' - dataType: string - lineageTag: a804462d-34e5-498d-ae01-0ba78750329e - summarizeBy: none - sourceColumn: properties.extendedProperties.Region - - annotation SummarizationSetBy = Automatic - - column 'properties.extendedProperties.lookbackPeriod' - dataType: string - lineageTag: e0579f64-a229-40fd-b0d2-6a6c7baf8052 - summarizeBy: none - sourceColumn: properties.extendedProperties.lookbackPeriod - - annotation SummarizationSetBy = Automatic - - column 'properties.extendedProperties.subId' - dataType: string - lineageTag: b2ca600b-c8f6-42db-9edc-97ca64a5429e - summarizeBy: none - sourceColumn: properties.extendedProperties.subId - - annotation SummarizationSetBy = Automatic - - column 'properties.extendedProperties.scope' - dataType: string - lineageTag: 32e4dd3a-74a6-4e20-9005-55bfbcd3ac7e - summarizeBy: none - sourceColumn: properties.extendedProperties.scope - - annotation SummarizationSetBy = Automatic - - column 'properties.extendedProperties.term' - dataType: string - lineageTag: 12b6fe8e-9c25-4287-8db1-23279ec5616e - summarizeBy: none - sourceColumn: properties.extendedProperties.term - - annotation SummarizationSetBy = Automatic - - column 'properties.extendedProperties.sku' - dataType: string - lineageTag: 9a56ac74-a4e4-44b0-b879-9d0d696aa06a - summarizeBy: none - sourceColumn: properties.extendedProperties.sku - - annotation SummarizationSetBy = Automatic - - column 'properties.extendedProperties.commitment' - dataType: string - lineageTag: c63f1307-bbd6-48c1-807f-9b5dcd0ad9cf - summarizeBy: none - sourceColumn: properties.extendedProperties.commitment - - annotation SummarizationSetBy = Automatic - - column 'properties.extendedProperties.currentSku' - dataType: string - lineageTag: 9ac388a6-51eb-4bec-aa68-5c13b7fe5c9b - summarizeBy: none - sourceColumn: properties.extendedProperties.currentSku - - annotation SummarizationSetBy = Automatic - - column 'properties.extendedProperties.targetSku' - dataType: string - lineageTag: 1ebb5230-bc88-4be3-8e7f-7ce06fbecce4 - summarizeBy: none - sourceColumn: properties.extendedProperties.targetSku - - annotation SummarizationSetBy = Automatic - - column 'properties.extendedProperties.recommendationMessage' - dataType: string - lineageTag: e0744324-2c7b-43b4-bc4d-bce14a18a0e2 - summarizeBy: none - sourceColumn: properties.extendedProperties.recommendationMessage - - annotation SummarizationSetBy = Automatic - - column 'properties.shortDescription.solution' - dataType: string - lineageTag: 9c791663-17ff-42a2-9648-ef4b12b2671e - summarizeBy: none - sourceColumn: properties.shortDescription.solution - - annotation SummarizationSetBy = Automatic - - column 'properties.shortDescription.problem' - dataType: string - lineageTag: 5c657cce-2d94-4eec-b526-7d20c72bec54 - summarizeBy: none - sourceColumn: properties.shortDescription.problem - - annotation SummarizationSetBy = Automatic - - column 'properties.resourceMetadata.resourceId' - dataType: string - lineageTag: 395d38f4-d4f6-4d30-94a2-ec3244abfed2 - summarizeBy: none - sourceColumn: properties.resourceMetadata.resourceId - - annotation SummarizationSetBy = Automatic - - column 'properties.resourceMetadata.singular' - dataType: string - lineageTag: 58f9df6d-d682-4bf8-9273-d141f30c4743 - summarizeBy: none - sourceColumn: properties.resourceMetadata.singular - - annotation SummarizationSetBy = Automatic - - column 'properties.resourceMetadata.plural' - dataType: string - lineageTag: 86f40b1b-56c8-4b29-9ac2-7b2cbb6f9f19 - summarizeBy: none - sourceColumn: properties.resourceMetadata.plural - - annotation SummarizationSetBy = Automatic - - column 'properties.resourceMetadata.action' - dataType: string - lineageTag: 1cdc271b-78aa-45e9-b85c-89684dddf18c - summarizeBy: none - sourceColumn: properties.resourceMetadata.action - - annotation SummarizationSetBy = Automatic - - column 'properties.resourceMetadata.source' - dataType: string - lineageTag: c83167c4-f804-4568-8894-a9ffd8d0fdd9 - summarizeBy: none - sourceColumn: properties.resourceMetadata.source - - annotation SummarizationSetBy = Automatic - - column 'properties.suppressionIds' - dataType: string - lineageTag: 8761bfa3-8cb3-4d24-984e-c0cb3482a2a0 - summarizeBy: none - sourceColumn: properties.suppressionIds - - annotation SummarizationSetBy = Automatic - - column 'properties.impactedField' - dataType: string - lineageTag: 26285858-61f3-4efd-8201-9f79d3f877cd - summarizeBy: none - sourceColumn: properties.impactedField - - annotation SummarizationSetBy = Automatic - - column 'properties.impactedValue' - dataType: string - lineageTag: 62951291-b70a-47eb-bbfd-74e781fef07e - summarizeBy: none - sourceColumn: properties.impactedValue - - annotation SummarizationSetBy = Automatic - - column 'properties.category' - dataType: string - lineageTag: d4071f11-546e-49cc-9131-675482ae0927 - summarizeBy: none - sourceColumn: properties.category - - annotation SummarizationSetBy = Automatic - - column 'properties.metadata' - dataType: string - lineageTag: 9888db80-3867-4fe4-8600-661836e054a1 - summarizeBy: none - sourceColumn: properties.metadata - - annotation SummarizationSetBy = Automatic - - column 'properties.impact' - dataType: string - lineageTag: 62f29742-9472-4678-b789-5da41abf1051 - summarizeBy: none - sourceColumn: properties.impact - sortByColumn: SortOrder - - changedProperty = SortByColumn - - annotation SummarizationSetBy = Automatic - - column SortOrder - dataType: double - formatString: 0 - lineageTag: 4d8ca85e-f35a-4e71-866b-188c3de4f284 - summarizeBy: sum - sourceColumn: SortOrder - - annotation SummarizationSetBy = Automatic - - column 'properties.shortDescription' - dataType: string - lineageTag: db36be30-e93a-4d83-8723-cfd5fef8ec31 - summarizeBy: none - sourceColumn: properties.shortDescription - - annotation SummarizationSetBy = Automatic - - column 'properties.resourceMetadata' - dataType: string - lineageTag: d1efb6c5-bd4f-40af-a43e-69e7576a48a1 - summarizeBy: none - sourceColumn: properties.resourceMetadata - - annotation SummarizationSetBy = Automatic - - column 'properties.lastUpdated' - dataType: dateTime - formatString: General Date - lineageTag: 432519ca-6b39-470a-875a-7011290482ba - summarizeBy: none - sourceColumn: properties.lastUpdated - - annotation SummarizationSetBy = Automatic - - column 'properties.extendedProperties.savingsAmount' - dataType: double - lineageTag: 588d3c29-5bb7-4bb6-a5bd-b35aedd8131a - summarizeBy: sum - sourceColumn: properties.extendedProperties.savingsAmount - - annotation SummarizationSetBy = Automatic - - annotation PBI_FormatHint = {"isGeneralNumber":true} - - column type - dataType: string - lineageTag: ac61d87d-1570-4b1a-97b1-0178fc944bb3 - summarizeBy: none - sourceColumn: type - - annotation SummarizationSetBy = Automatic - - column tenantId - dataType: string - lineageTag: 9f303a32-9ab0-4a62-97b5-09ce9630feee - summarizeBy: none - sourceColumn: tenantId - - annotation SummarizationSetBy = Automatic - - column kind - dataType: string - lineageTag: a113728e-e322-41d5-9605-c61609c31352 - summarizeBy: none - sourceColumn: kind - - annotation SummarizationSetBy = Automatic - - column location - dataType: string - lineageTag: 763782ff-4b2b-4c62-88ab-81426f80db79 - summarizeBy: none - sourceColumn: location - - annotation SummarizationSetBy = Automatic - - column resourceGroup - dataType: string - lineageTag: 9d01f317-2b3c-429a-9edd-d5e000cf7eab - summarizeBy: none - sourceColumn: resourceGroup - - annotation SummarizationSetBy = Automatic - - column subscriptionId - dataType: string - lineageTag: 64459c7e-80f2-42d2-b149-27201ab28ecc - summarizeBy: none - sourceColumn: subscriptionId - - annotation SummarizationSetBy = Automatic - - column managedBy - dataType: string - lineageTag: 8115cac1-1999-4fd2-acd9-198d1efa40a1 - summarizeBy: none - sourceColumn: managedBy - - annotation SummarizationSetBy = Automatic - - column sku - dataType: string - lineageTag: c6148b22-09be-4d0d-9ffe-5ecc3a0fdf15 - summarizeBy: none - sourceColumn: sku - - annotation SummarizationSetBy = Automatic - - column plan - dataType: string - lineageTag: 20739f02-9f27-49a4-b777-72b7a22d11c9 - summarizeBy: none - sourceColumn: plan - - annotation SummarizationSetBy = Automatic - - column properties - dataType: string - lineageTag: 5a807d2f-0fd7-4cc4-8148-fb54899da4fa - summarizeBy: none - sourceColumn: properties - - annotation SummarizationSetBy = Automatic - - column tags - dataType: string - lineageTag: efb6b31c-93d6-4eda-9033-31af080009fe - summarizeBy: none - sourceColumn: tags - - annotation SummarizationSetBy = Automatic - - column identity - dataType: string - lineageTag: edf81095-af38-4974-9320-6567dd06ae16 - summarizeBy: none - sourceColumn: identity - - annotation SummarizationSetBy = Automatic - - column zones - dataType: string - lineageTag: 8338ea34-4f56-4839-a052-d7a72d4ba7b4 - summarizeBy: none - sourceColumn: zones - - annotation SummarizationSetBy = Automatic - - column extendedLocation - dataType: string - lineageTag: 64c356d0-098f-431c-bf9c-929f991acb02 - summarizeBy: none - sourceColumn: extendedLocation - - annotation SummarizationSetBy = Automatic - - partition AdvisorRecommendations = m - mode: import - queryGroup: 'Resource Graph' - source = ``` - let - Source = AzureResourceGraph.Query(" - - - advisorresources - | where type == 'microsoft.advisor/recommendations' - | where properties.category == 'Cost' - | extend - ['properties.recommendationTypeId'] = properties.recommendationTypeId, - ['properties.shortDescription'] = properties.shortDescription, - ['properties.resourceMetadata'] = properties.resourceMetadata, - ['properties.suppressionIds'] = properties.suppressionIds, - ['properties.impactedField'] = properties.impactedField, - ['properties.impactedValue'] = properties.impactedValue, - ['properties.lastUpdated'] = properties.lastUpdated, - ['properties.category'] = properties.category, - ['properties.metadata'] = properties.metadata, - ['properties.impact'] = properties.impact, - ['properties.shortDescription.problem'] = properties.shortDescription.problem, - ['properties.shortDescription.solution'] = properties.shortDescription.solution, - ['properties.extendedProperties.ObservationPeriodStartDate'] = properties.extendedProperties.ObservationPeriodStartDate, - ['properties.extendedProperties.ObservationPeriodEndDate'] = properties.extendedProperties.ObservationPeriodEndDate, - ['properties.extendedProperties.annualSavingsAmount'] = coalesce(properties.extendedProperties.annualSavingsAmount, 0), - ['properties.extendedProperties.HasRecommendation'] = properties.extendedProperties.HasRecommendation, - ['properties.extendedProperties.savingsCurrency'] = properties.extendedProperties.savingsCurrency, - ['properties.extendedProperties.IsInReplication'] = properties.extendedProperties.IsInReplication, - ['properties.extendedProperties.Recommended_DTU'] = properties.extendedProperties.Recommended_DTU, - ['properties.extendedProperties.Recommended_SKU'] = properties.extendedProperties.Recommended_SKU, - ['properties.extendedProperties.ResourceGroup'] = tolower(properties.extendedProperties.ResourceGroup), - ['properties.extendedProperties.savingsAmount'] = coalesce(properties.extendedProperties.savingsAmount, 0), - ['properties.extendedProperties.DatabaseSize'] = properties.extendedProperties.DatabaseSize, - ['properties.extendedProperties.DatabaseName'] = properties.extendedProperties.DatabaseName, - ['properties.extendedProperties.ServerName'] = properties.extendedProperties.ServerName, - ['properties.extendedProperties.Region'] = properties.extendedProperties.Region, - ['properties.extendedProperties.lookbackPeriod'] = properties.extendedProperties.lookbackPeriod, - ['properties.extendedProperties.subId'] = properties.extendedProperties.subId, - ['properties.extendedProperties.scope'] = properties.extendedProperties.scope, - ['properties.extendedProperties.term'] = properties.extendedProperties.term, - ['properties.extendedProperties.sku'] = properties.extendedProperties.sku, - ['properties.extendedProperties.commitment'] = properties.extendedProperties.commitment, - ['properties.extendedProperties.currentSku'] = properties.extendedProperties.currentSku, - ['properties.extendedProperties.targetSku'] = properties.extendedProperties.targetSku, - ['properties.extendedProperties.recommendationMessage'] = properties.extendedProperties.recommendationMessage, - ['properties.resourceMetadata.resourceId'] = tolower(properties.resourceMetadata.resourceId), - ['properties.resourceMetadata.singular'] = properties.resourceMetadata.singular, - ['properties.resourceMetadata.plural'] = properties.resourceMetadata.plural, - ['properties.resourceMetadata.action'] = properties.resourceMetadata.action, - ['properties.resourceMetadata.source'] = properties.resourceMetadata.source, - SortOrder = case(properties.impact == 'High', 1, properties.impact == 'Medium', 2, properties.impact == 'Low', 3, 9) - - - " & ftk_DemoFilter(), "Tenant", null, null, [resultTruncated = true]), - NullHandling = - if Table.HasColumns(Source, "Results") and Table.RowCount(Source) = 1 then - #table( - { "id", "name", "type", "properties.recommendationTypeId", "properties.shortDescription", "properties.resourceMetadata", "properties.suppressionIds", "properties.impactedField", "properties.impactedValue", "properties.lastUpdated", "properties.category", "properties.metadata", "properties.impact", "properties.shortDescription.problem", "properties.shortDescription.solution", "properties.extendedProperties.ObservationPeriodStartDate", "properties.extendedProperties.ObservationPeriodEndDate", "properties.extendedProperties.annualSavingsAmount", "properties.extendedProperties.HasRecommendation", "properties.extendedProperties.savingsCurrency", "properties.extendedProperties.IsInReplication", "properties.extendedProperties.Recommended_DTU", "properties.extendedProperties.Recommended_SKU", "properties.extendedProperties.ResourceGroup", "properties.extendedProperties.savingsAmount", "properties.extendedProperties.DatabaseSize", "properties.extendedProperties.DatabaseName", "properties.extendedProperties.ServerName", "properties.extendedProperties.Region", "properties.extendedProperties.lookbackPeriod", "properties.extendedProperties.subId", "properties.extendedProperties.scope", "properties.extendedProperties.term", "properties.extendedProperties.sku", "properties.extendedProperties.commitment", "properties.extendedProperties.currentSku", "properties.extendedProperties.targetSku", "properties.extendedProperties.recommendationMessage", "properties.resourceMetadata.resourceId", "properties.resourceMetadata.singular", "properties.resourceMetadata.plural", "properties.resourceMetadata.action", "properties.resourceMetadata.source", "SortOrder" }, - {} - ) - else Source, - Types = Table.TransformColumnTypes(NullHandling, { - {"properties.extendedProperties.annualSavingsAmount", type number}, - {"properties.extendedProperties.savingsAmount", type number}, - {"SortOrder", type number}, - {"properties.extendedProperties.ObservationPeriodStartDate", type datetimezone}, - {"properties.extendedProperties.ObservationPeriodEndDate", type datetimezone}, - {"properties.lastUpdated", type datetimezone} - }, "en-US") - in - Types - ``` - - annotation PBI_NavigationStepName = Navigation - - annotation PBI_ResultType = Table - diff --git a/src/power-bi/storage/Shared.Dataset/definition/tables/AdvisorRecommendations.tmdl b/src/power-bi/storage/Shared.Dataset/definition/tables/AdvisorRecommendations.tmdl new file mode 120000 index 000000000..64dcaac16 --- /dev/null +++ b/src/power-bi/storage/Shared.Dataset/definition/tables/AdvisorRecommendations.tmdl @@ -0,0 +1 @@ +../../../../kql/Shared.Dataset/definition/tables/AdvisorRecommendations.tmdl \ No newline at end of file diff --git a/src/power-bi/storage/Shared.Dataset/definition/tables/AdvisorReservationRecommendations.tmdl b/src/power-bi/storage/Shared.Dataset/definition/tables/AdvisorReservationRecommendations.tmdl deleted file mode 100644 index 2ffb4878e..000000000 --- a/src/power-bi/storage/Shared.Dataset/definition/tables/AdvisorReservationRecommendations.tmdl +++ /dev/null @@ -1,547 +0,0 @@ -table AdvisorReservationRecommendations - lineageTag: e2be3b74-1430-4a74-bf1a-18576064c803 - - column id - dataType: string - lineageTag: e9cd6688-9a32-4da4-86e9-aed15b22652d - summarizeBy: none - sourceColumn: id - - annotation SummarizationSetBy = Automatic - - column name - dataType: string - lineageTag: 8eb22dcc-76d0-4491-9aa3-d264bcc05789 - summarizeBy: none - sourceColumn: name - - annotation SummarizationSetBy = Automatic - - column 'properties.recommendationTypeId' - dataType: string - lineageTag: badf977b-e853-4e53-a169-64a2dd84d1dd - summarizeBy: none - sourceColumn: properties.recommendationTypeId - - annotation SummarizationSetBy = Automatic - - column 'properties.extendedProperties.annualSavingsAmount' - dataType: double - lineageTag: 09d4b890-7c8d-4ee0-943d-4a9212c7091f - summarizeBy: sum - sourceColumn: properties.extendedProperties.annualSavingsAmount - - annotation SummarizationSetBy = Automatic - - annotation PBI_FormatHint = {"isGeneralNumber":true} - - column 'properties.extendedProperties.savingsCurrency' - dataType: string - lineageTag: 26882091-cceb-4825-8f25-e57c49d2353e - summarizeBy: none - sourceColumn: properties.extendedProperties.savingsCurrency - - annotation SummarizationSetBy = Automatic - - column 'properties.extendedProperties.lookbackPeriod' - dataType: string - lineageTag: 82a3a6d5-01c1-4db7-be17-572b62ceb699 - summarizeBy: none - sourceColumn: properties.extendedProperties.lookbackPeriod - - annotation SummarizationSetBy = Automatic - - column 'properties.extendedProperties.savingsAmount' - dataType: double - lineageTag: 99312e80-1a6c-4520-a5b0-645f69d8e310 - summarizeBy: sum - sourceColumn: properties.extendedProperties.savingsAmount - - annotation SummarizationSetBy = Automatic - - annotation PBI_FormatHint = {"isGeneralNumber":true} - - column 'properties.extendedProperties.subId' - dataType: string - lineageTag: dbbb8676-ac50-4761-bbd4-3b570710c2f4 - summarizeBy: none - sourceColumn: properties.extendedProperties.subId - - annotation SummarizationSetBy = Automatic - - column 'properties.extendedProperties.scope' - dataType: string - lineageTag: a1352eea-bc3b-468c-a288-178d8cdb770f - summarizeBy: none - sourceColumn: properties.extendedProperties.scope - - annotation SummarizationSetBy = Automatic - - column 'properties.extendedProperties.term' - dataType: string - lineageTag: 60bc379d-ff92-4d80-89c0-e20addb02ae7 - summarizeBy: none - sourceColumn: properties.extendedProperties.term - - annotation SummarizationSetBy = Automatic - - column 'properties.extendedProperties.sku' - dataType: string - lineageTag: 9754b4be-44c4-46ed-b53a-0cd3c0d3b32c - summarizeBy: none - sourceColumn: properties.extendedProperties.sku - - annotation SummarizationSetBy = Automatic - - column 'properties.resourceMetadata.resourceId' - dataType: string - lineageTag: c1a5553c-a8e2-44b6-a4e2-ee173b5b88ff - summarizeBy: none - sourceColumn: properties.resourceMetadata.resourceId - - annotation SummarizationSetBy = Automatic - - column 'properties.resourceMetadata.singular' - dataType: string - lineageTag: aadd862e-b506-4ae6-849a-8a83c0744c65 - summarizeBy: none - sourceColumn: properties.resourceMetadata.singular - - annotation SummarizationSetBy = Automatic - - column 'properties.resourceMetadata.plural' - dataType: string - lineageTag: 3973f04a-8d35-415e-b06e-4ec8dbfe9048 - summarizeBy: none - sourceColumn: properties.resourceMetadata.plural - - annotation SummarizationSetBy = Automatic - - column 'properties.resourceMetadata.action' - dataType: string - lineageTag: 8c8a5ac4-e51d-4fa2-a031-0cb29c29db82 - summarizeBy: none - sourceColumn: properties.resourceMetadata.action - - annotation SummarizationSetBy = Automatic - - column 'properties.resourceMetadata.source' - dataType: string - lineageTag: 4cb277aa-3319-4aaa-8c6a-a49e9a4a11ab - summarizeBy: none - sourceColumn: properties.resourceMetadata.source - - annotation SummarizationSetBy = Automatic - - column 'properties.shortDescription.solution' - dataType: string - lineageTag: 98412b8a-854a-4292-a30c-8e096ce4c728 - summarizeBy: none - sourceColumn: properties.shortDescription.solution - - annotation SummarizationSetBy = Automatic - - column 'properties.shortDescription.problem' - dataType: string - lineageTag: e31a4cd0-a5f9-4a5f-bea6-ecff0be2ea13 - summarizeBy: none - sourceColumn: properties.shortDescription.problem - - annotation SummarizationSetBy = Automatic - - column 'properties.suppressionIds' - dataType: string - lineageTag: aa582a0d-0c5f-49dd-93f2-3363bb02828c - summarizeBy: none - sourceColumn: properties.suppressionIds - - annotation SummarizationSetBy = Automatic - - column 'properties.impactedField' - dataType: string - lineageTag: c0947fb9-3d13-4cad-a274-bb58dc488100 - summarizeBy: none - sourceColumn: properties.impactedField - - annotation SummarizationSetBy = Automatic - - column 'properties.impactedValue' - dataType: string - lineageTag: d803c460-7f91-4c6e-9649-a28d90b8f2a2 - summarizeBy: none - sourceColumn: properties.impactedValue - - annotation SummarizationSetBy = Automatic - - column 'properties.lastUpdated' - dataType: dateTime - formatString: General Date - lineageTag: b93e22ab-02ec-4821-aff7-4a45b86fee21 - summarizeBy: none - sourceColumn: properties.lastUpdated - - annotation SummarizationSetBy = Automatic - - column 'properties.metadata' - dataType: string - lineageTag: 055caf5c-5b7b-428a-b4a1-0b4c68ca55b9 - summarizeBy: none - sourceColumn: properties.metadata - - annotation SummarizationSetBy = Automatic - - column 'properties.category' - dataType: string - lineageTag: 0bdec23f-098b-486d-870d-3df3e3fb737c - summarizeBy: none - sourceColumn: properties.category - - annotation SummarizationSetBy = Automatic - - column 'properties.impact' - dataType: string - lineageTag: a6596380-928f-4559-a334-26c33b67c4a9 - summarizeBy: none - sourceColumn: properties.impact - - annotation SummarizationSetBy = Automatic - - column 'properties.shortDescription' - dataType: string - lineageTag: 34fae73f-1cea-4fab-8ee4-9c406b4e5de2 - summarizeBy: none - sourceColumn: properties.shortDescription - - annotation SummarizationSetBy = Automatic - - column 'properties.resourceMetadata' - dataType: string - lineageTag: 6399ea0e-c284-4fb8-84e4-a8994d38b8d2 - summarizeBy: none - sourceColumn: properties.resourceMetadata - - annotation SummarizationSetBy = Automatic - - column type - dataType: string - lineageTag: 16f6fad3-9392-43a0-8414-17d80c82489b - summarizeBy: none - sourceColumn: type - - annotation SummarizationSetBy = Automatic - - column tenantId - dataType: string - lineageTag: 944b83f2-1e35-43d1-b712-f8488a690464 - summarizeBy: none - sourceColumn: tenantId - - annotation SummarizationSetBy = Automatic - - column kind - dataType: string - lineageTag: a16fb1e8-681c-4133-8c2b-ac38888c4f0a - summarizeBy: none - sourceColumn: kind - - annotation SummarizationSetBy = Automatic - - column location - dataType: string - lineageTag: 3702fe61-d409-4c8d-8be1-cba17061e33e - summarizeBy: none - sourceColumn: location - - annotation SummarizationSetBy = Automatic - - column resourceGroup - dataType: string - lineageTag: bbcbb6da-7975-49eb-8f02-f2d7dcb5dc0f - summarizeBy: none - sourceColumn: resourceGroup - - annotation SummarizationSetBy = Automatic - - column subscriptionId - dataType: string - lineageTag: c90deea5-7ac8-438f-a194-7d97640da5f9 - summarizeBy: none - sourceColumn: subscriptionId - - annotation SummarizationSetBy = Automatic - - column managedBy - dataType: string - lineageTag: 32f1ed8e-b5fc-40f8-a90e-2e1f87171ace - summarizeBy: none - sourceColumn: managedBy - - annotation SummarizationSetBy = Automatic - - column sku - dataType: string - lineageTag: 482c2e98-e7f4-40fe-8a05-1fd4a70f6fee - summarizeBy: none - sourceColumn: sku - - annotation SummarizationSetBy = Automatic - - column plan - dataType: string - lineageTag: c59c57c5-74ab-41de-af37-a23d1dca2ecc - summarizeBy: none - sourceColumn: plan - - annotation SummarizationSetBy = Automatic - - column properties - dataType: string - lineageTag: 8d40212f-93f6-489a-8a48-002238128415 - summarizeBy: none - sourceColumn: properties - - annotation SummarizationSetBy = Automatic - - column tags - dataType: string - lineageTag: 959f8886-ecee-40bc-b1b7-78d0684f2d66 - summarizeBy: none - sourceColumn: tags - - annotation SummarizationSetBy = Automatic - - column identity - dataType: string - lineageTag: 2c5dfecb-d165-4f56-8a05-bad2ba1e07cc - summarizeBy: none - sourceColumn: identity - - annotation SummarizationSetBy = Automatic - - column zones - dataType: string - lineageTag: 2af41178-da35-4296-bfea-d430c5f24fe2 - summarizeBy: none - sourceColumn: zones - - annotation SummarizationSetBy = Automatic - - column extendedLocation - dataType: string - lineageTag: 63619dfc-ce80-4af4-b3a1-345ab5604a66 - summarizeBy: none - sourceColumn: extendedLocation - - annotation SummarizationSetBy = Automatic - - column 'properties.extendedProperties.ObservationPeriodStartDate' - dataType: dateTime - formatString: General Date - lineageTag: 1e286848-dabb-4034-8913-cd9cf2144716 - summarizeBy: none - sourceColumn: properties.extendedProperties.ObservationPeriodStartDate - - annotation SummarizationSetBy = Automatic - - column 'properties.extendedProperties.ObservationPeriodEndDate' - dataType: dateTime - formatString: General Date - lineageTag: 55c1b862-e2f9-4655-aedc-1e5d5b02e2d4 - summarizeBy: none - sourceColumn: properties.extendedProperties.ObservationPeriodEndDate - - annotation SummarizationSetBy = Automatic - - column 'properties.extendedProperties.HasRecommendation' - dataType: string - lineageTag: b87c10ce-9453-41d4-b56b-680bae8ac4a2 - summarizeBy: none - sourceColumn: properties.extendedProperties.HasRecommendation - - annotation SummarizationSetBy = Automatic - - column 'properties.extendedProperties.IsInReplication' - dataType: string - lineageTag: 7a6be7dd-254a-45a5-8aba-3ca27eca2b5b - summarizeBy: none - sourceColumn: properties.extendedProperties.IsInReplication - - annotation SummarizationSetBy = Automatic - - column 'properties.extendedProperties.Recommended_DTU' - dataType: string - lineageTag: 48b988f9-4dc0-4f84-86a8-8c3b87940179 - summarizeBy: none - sourceColumn: properties.extendedProperties.Recommended_DTU - - annotation SummarizationSetBy = Automatic - - column 'properties.extendedProperties.Recommended_SKU' - dataType: string - lineageTag: 0a0fdca3-221d-4572-aed6-5c840358cb69 - summarizeBy: none - sourceColumn: properties.extendedProperties.Recommended_SKU - - annotation SummarizationSetBy = Automatic - - column 'properties.extendedProperties.ResourceGroup' - dataType: string - lineageTag: f5ffcebb-d130-457c-a298-6d462eea16bb - summarizeBy: none - sourceColumn: properties.extendedProperties.ResourceGroup - - annotation SummarizationSetBy = Automatic - - column 'properties.extendedProperties.DatabaseSize' - dataType: string - lineageTag: 42dffd26-268e-49a1-b047-99e8c0f7f104 - summarizeBy: none - sourceColumn: properties.extendedProperties.DatabaseSize - - annotation SummarizationSetBy = Automatic - - column 'properties.extendedProperties.DatabaseName' - dataType: string - lineageTag: f74bb29d-f74d-4c35-bc25-66818909cfcc - summarizeBy: none - sourceColumn: properties.extendedProperties.DatabaseName - - annotation SummarizationSetBy = Automatic - - column 'properties.extendedProperties.ServerName' - dataType: string - lineageTag: 804d5612-8c2e-4881-a80b-37968100ba21 - summarizeBy: none - sourceColumn: properties.extendedProperties.ServerName - - annotation SummarizationSetBy = Automatic - - column 'properties.extendedProperties.Region' - dataType: string - lineageTag: 68593266-9950-4caf-9522-ccfcbaa5d5e3 - summarizeBy: none - sourceColumn: properties.extendedProperties.Region - - annotation SummarizationSetBy = Automatic - - column 'properties.extendedProperties.commitment' - dataType: string - lineageTag: e0b87d0c-8c42-4354-b85a-5fc93d4af06a - summarizeBy: none - sourceColumn: properties.extendedProperties.commitment - - annotation SummarizationSetBy = Automatic - - column 'properties.extendedProperties.currentSku' - dataType: string - lineageTag: 11320610-15d3-4db1-89b5-746d92fbf0fa - summarizeBy: none - sourceColumn: properties.extendedProperties.currentSku - - annotation SummarizationSetBy = Automatic - - column 'properties.extendedProperties.targetSku' - dataType: string - lineageTag: 9a5c5a7c-8a59-4445-8946-d13f64fb3091 - summarizeBy: none - sourceColumn: properties.extendedProperties.targetSku - - annotation SummarizationSetBy = Automatic - - column 'properties.extendedProperties.recommendationMessage' - dataType: string - lineageTag: b2c1b5c3-ae28-4630-8823-d2db3604a1fb - summarizeBy: none - sourceColumn: properties.extendedProperties.recommendationMessage - - annotation SummarizationSetBy = Automatic - - column SortOrder - dataType: double - lineageTag: 0abaa4e9-cb2e-49bf-97ab-a0e6f54d3cb2 - summarizeBy: sum - sourceColumn: SortOrder - - annotation SummarizationSetBy = Automatic - - annotation PBI_FormatHint = {"isGeneralNumber":true} - - partition AdvisorReservationRecommendations = m - mode: import - queryGroup: 'Resource Graph' - source = ``` - let - Source = AzureResourceGraph.Query(" - - - advisorresources - | where type == 'microsoft.advisor/recommendations' - | where properties.category == 'Cost' - | extend - ['properties.recommendationTypeId'] = properties.recommendationTypeId, - ['properties.shortDescription'] = properties.shortDescription, - ['properties.resourceMetadata'] = properties.resourceMetadata, - ['properties.suppressionIds'] = properties.suppressionIds, - ['properties.impactedField'] = properties.impactedField, - ['properties.impactedValue'] = properties.impactedValue, - ['properties.lastUpdated'] = properties.lastUpdated, - ['properties.category'] = properties.category, - ['properties.metadata'] = properties.metadata, - ['properties.impact'] = properties.impact, - ['properties.shortDescription.problem'] = properties.shortDescription.problem, - ['properties.shortDescription.solution'] = properties.shortDescription.solution, - ['properties.extendedProperties.ObservationPeriodStartDate'] = properties.extendedProperties.ObservationPeriodStartDate, - ['properties.extendedProperties.ObservationPeriodEndDate'] = properties.extendedProperties.ObservationPeriodEndDate, - ['properties.extendedProperties.annualSavingsAmount'] = coalesce(properties.extendedProperties.annualSavingsAmount, 0), - ['properties.extendedProperties.HasRecommendation'] = properties.extendedProperties.HasRecommendation, - ['properties.extendedProperties.savingsCurrency'] = properties.extendedProperties.savingsCurrency, - ['properties.extendedProperties.IsInReplication'] = properties.extendedProperties.IsInReplication, - ['properties.extendedProperties.Recommended_DTU'] = properties.extendedProperties.Recommended_DTU, - ['properties.extendedProperties.Recommended_SKU'] = properties.extendedProperties.Recommended_SKU, - ['properties.extendedProperties.ResourceGroup'] = tolower(properties.extendedProperties.ResourceGroup), - ['properties.extendedProperties.savingsAmount'] = coalesce(properties.extendedProperties.savingsAmount, 0), - ['properties.extendedProperties.DatabaseSize'] = properties.extendedProperties.DatabaseSize, - ['properties.extendedProperties.DatabaseName'] = properties.extendedProperties.DatabaseName, - ['properties.extendedProperties.ServerName'] = properties.extendedProperties.ServerName, - ['properties.extendedProperties.Region'] = properties.extendedProperties.Region, - ['properties.extendedProperties.lookbackPeriod'] = properties.extendedProperties.lookbackPeriod, - ['properties.extendedProperties.subId'] = properties.extendedProperties.subId, - ['properties.extendedProperties.scope'] = properties.extendedProperties.scope, - ['properties.extendedProperties.term'] = properties.extendedProperties.term, - ['properties.extendedProperties.sku'] = properties.extendedProperties.sku, - ['properties.extendedProperties.commitment'] = properties.extendedProperties.commitment, - ['properties.extendedProperties.currentSku'] = properties.extendedProperties.currentSku, - ['properties.extendedProperties.targetSku'] = properties.extendedProperties.targetSku, - ['properties.extendedProperties.recommendationMessage'] = properties.extendedProperties.recommendationMessage, - ['properties.resourceMetadata.resourceId'] = tolower(properties.resourceMetadata.resourceId), - ['properties.resourceMetadata.singular'] = properties.resourceMetadata.singular, - ['properties.resourceMetadata.plural'] = properties.resourceMetadata.plural, - ['properties.resourceMetadata.action'] = properties.resourceMetadata.action, - ['properties.resourceMetadata.source'] = properties.resourceMetadata.source, - SortOrder = case(properties.impact == 'High', 1, properties.impact == 'Medium', 2, properties.impact == 'Low', 3, 9) - - - " & ftk_DemoFilter(), "Tenant", null, null, [resultTruncated = true]), - NullHandling = - if Table.HasColumns(Source, "Results") and Table.RowCount(Source) = 1 then - #table( - { "id", "name", "type", "properties.recommendationTypeId", "properties.shortDescription", "properties.resourceMetadata", "properties.suppressionIds", "properties.impactedField", "properties.impactedValue", "properties.lastUpdated", "properties.category", "properties.metadata", "properties.impact", "properties.shortDescription.problem", "properties.shortDescription.solution", "properties.extendedProperties.ObservationPeriodStartDate", "properties.extendedProperties.ObservationPeriodEndDate", "properties.extendedProperties.annualSavingsAmount", "properties.extendedProperties.HasRecommendation", "properties.extendedProperties.savingsCurrency", "properties.extendedProperties.IsInReplication", "properties.extendedProperties.Recommended_DTU", "properties.extendedProperties.Recommended_SKU", "properties.extendedProperties.ResourceGroup", "properties.extendedProperties.savingsAmount", "properties.extendedProperties.DatabaseSize", "properties.extendedProperties.DatabaseName", "properties.extendedProperties.ServerName", "properties.extendedProperties.Region", "properties.extendedProperties.lookbackPeriod", "properties.extendedProperties.subId", "properties.extendedProperties.scope", "properties.extendedProperties.term", "properties.extendedProperties.sku", "properties.extendedProperties.commitment", "properties.extendedProperties.currentSku", "properties.extendedProperties.targetSku", "properties.extendedProperties.recommendationMessage", "properties.resourceMetadata.resourceId", "properties.resourceMetadata.singular", "properties.resourceMetadata.plural", "properties.resourceMetadata.action", "properties.resourceMetadata.source", "SortOrder" }, - {} - ) - else Source, - Types = Table.TransformColumnTypes(NullHandling, { - {"properties.extendedProperties.annualSavingsAmount", type number}, - {"properties.extendedProperties.savingsAmount", type number}, - {"SortOrder", type number}, - {"properties.extendedProperties.ObservationPeriodStartDate", type datetimezone}, - {"properties.extendedProperties.ObservationPeriodEndDate", type datetimezone}, - {"properties.lastUpdated", type datetimezone} - }, "en-US") - in - Types - ``` - - annotation PBI_NavigationStepName = Navigation - - annotation PBI_ResultType = Table - diff --git a/src/power-bi/storage/Shared.Dataset/definition/tables/AdvisorReservationRecommendations.tmdl b/src/power-bi/storage/Shared.Dataset/definition/tables/AdvisorReservationRecommendations.tmdl new file mode 120000 index 000000000..03bc82802 --- /dev/null +++ b/src/power-bi/storage/Shared.Dataset/definition/tables/AdvisorReservationRecommendations.tmdl @@ -0,0 +1 @@ +../../../../kql/Shared.Dataset/definition/tables/AdvisorReservationRecommendations.tmdl \ No newline at end of file diff --git a/src/power-bi/storage/Shared.Dataset/definition/tables/Disks.tmdl b/src/power-bi/storage/Shared.Dataset/definition/tables/Disks.tmdl deleted file mode 100644 index 34ceb98ac..000000000 --- a/src/power-bi/storage/Shared.Dataset/definition/tables/Disks.tmdl +++ /dev/null @@ -1,224 +0,0 @@ -table Disks - lineageTag: 0008230d-7a07-40e4-ba7f-cef258f5ac62 - - column subscriptionId - dataType: string - lineageTag: 7622c7b1-5d51-4063-97f3-75e8098198d4 - summarizeBy: none - sourceColumn: subscriptionId - - annotation SummarizationSetBy = Automatic - - column name - dataType: string - lineageTag: d7dc5a6b-6850-421c-90be-26ef85476a28 - summarizeBy: none - sourceColumn: name - - annotation SummarizationSetBy = Automatic - - column tenantId - dataType: string - lineageTag: 70f65b8a-76e4-4f5f-8b89-28b315f2366a - summarizeBy: none - sourceColumn: tenantId - - annotation SummarizationSetBy = Automatic - - column location - dataType: string - lineageTag: bae1fb2b-ef36-4a5c-b266-7ee626ecafc1 - summarizeBy: none - sourceColumn: location - - annotation SummarizationSetBy = Automatic - - column managedBy - dataType: string - lineageTag: cf9f6e5f-aa49-49d0-a6c0-5a86337daaaf - summarizeBy: none - sourceColumn: managedBy - - annotation SummarizationSetBy = Automatic - - column osType - dataType: string - lineageTag: 2813c211-256f-4d18-8bed-13509d542b05 - summarizeBy: none - sourceColumn: osType - - annotation SummarizationSetBy = Automatic - - column skuName - dataType: string - lineageTag: b7e73136-b3db-4353-9c6d-b589f11dcd80 - summarizeBy: none - sourceColumn: skuName - - annotation SummarizationSetBy = Automatic - - column skuTier - dataType: string - lineageTag: 56d25952-5baa-43b1-995b-1e4b2de85c12 - summarizeBy: none - sourceColumn: skuTier - - annotation SummarizationSetBy = Automatic - - column diskSizeGB - dataType: double - formatString: 0 - lineageTag: 3d096969-5e1d-4c86-b27b-4a5052afaade - summarizeBy: sum - sourceColumn: diskSizeGB - - annotation SummarizationSetBy = Automatic - - annotation PBI_FormatHint = {"isDecimal":true} - - column diskMBpsReadWrite - dataType: double - lineageTag: 553574b1-e3d9-4770-8f7f-c05d6a1763e3 - summarizeBy: sum - sourceColumn: diskMBpsReadWrite - - annotation SummarizationSetBy = Automatic - - annotation PBI_FormatHint = {"isGeneralNumber":true} - - column diskIOPSReadWrite - dataType: double - lineageTag: d614472f-ffe3-45dd-ba19-50ddd2e628e6 - summarizeBy: sum - sourceColumn: diskIOPSReadWrite - - annotation SummarizationSetBy = Automatic - - annotation PBI_FormatHint = {"isGeneralNumber":true} - - column diskState - dataType: string - lineageTag: 0c4f4703-181e-4f33-8b15-f16a72d2278c - summarizeBy: none - sourceColumn: diskState - - annotation SummarizationSetBy = Automatic - - column timeCreated - dataType: dateTime - formatString: General Date - lineageTag: f329e820-03af-4e98-849d-e94e9de82d56 - summarizeBy: none - sourceColumn: timeCreated - - annotation SummarizationSetBy = Automatic - - column LastOwnershipUpdateTime - dataType: dateTime - formatString: dd/mm/yyyy - lineageTag: 48d08bc6-f897-48a9-9447-788df9150f94 - summarizeBy: none - sourceColumn: LastOwnershipUpdateTime - - annotation SummarizationSetBy = Automatic - - annotation PBI_FormatHint = {"isDateTimeCustom":true} - - column diskType - dataType: string - lineageTag: cb5aa8fb-6998-4746-b91a-c4241254bf26 - summarizeBy: none - sourceColumn: diskType - - annotation SummarizationSetBy = Automatic - - column parentVM - dataType: string - lineageTag: c3703ad8-91fb-4863-867e-c77389dd7d35 - summarizeBy: none - sourceColumn: parentVM - - annotation SummarizationSetBy = Automatic - - column Redundancy - dataType: string - lineageTag: 757f9390-cb96-46cb-8cad-ef02b08ba1ae - summarizeBy: none - sourceColumn: Redundancy - - annotation SummarizationSetBy = Automatic - - column id - dataType: string - lineageTag: aced1051-4fe8-4335-8f7d-b1bd4987f29c - summarizeBy: none - sourceColumn: id - - annotation SummarizationSetBy = Automatic - - column resourceGroup - dataType: string - lineageTag: 20d3ce4e-e586-49c6-a1c2-ce16d524d12a - summarizeBy: none - sourceColumn: resourceGroup - - annotation SummarizationSetBy = Automatic - - partition Disks = m - mode: import - queryGroup: 'Resource Graph' - source = - let - query = " - resources - | where type =~ 'microsoft.compute/disks' - | extend id = tolower(id) - | extend skuName = sku.name - | extend skuTier = sku.tier - | extend timeCreated = properties.timeCreated - | extend diskSizeGB = properties.diskSizeGB - | extend diskState = properties.diskState - | extend LastOwnershipUpdateTime = properties.LastOwnershipUpdateTime - | extend diskMBpsReadWrite = properties.diskMBpsReadWrite - | extend diskIOPSReadWrite = properties.diskIOPSReadWrite - | extend osType = properties.osType - | extend diskType = iff(isnull(osType), 'Data disk', 'OS disk') - | parse kind=regex skuName with '_' Redundancy - | parse kind=regex managedBy with 'virtualMachines/' parentVM - | project - subscriptionId, - resourceGroup, - id, - name, - tenantId, - location, - managedBy, - osType, - skuName, - skuTier, - diskSizeGB, - diskMBpsReadWrite, - diskIOPSReadWrite, - diskState, - timeCreated, - LastOwnershipUpdateTime, - Redundancy, - parentVM, - diskType - " & ftk_DemoFilter(), - Source = AzureResourceGraph.Query(query, "Tenant", null, null, [resultTruncated = false]), - NullHandling = - if Table.HasColumns(Source, "Results") and Table.RowCount(Source) = 1 then - #table( - { "id", "name", "subscriptionId", "resourceGroup", "tenantId", "location", "managedBy", "osType", "skuName", "skuTier", "diskSizeGB", "diskMBpsReadWrite", "diskIOPSReadWrite", "diskState", "timeCreated", "LastOwnershipUpdateTime", "Redundancy", "parentVM", "diskType" }, - {} - ) - else Source, - Types = Table.TransformColumnTypes(NullHandling,{{"diskSizeGB", type number}, {"diskMBpsReadWrite", type number}, {"diskIOPSReadWrite", type number}, {"timeCreated", type datetimezone}, {"LastOwnershipUpdateTime", type datetimezone}}) - in - Types - - annotation PBI_NavigationStepName = Navigation - - annotation PBI_ResultType = Table - diff --git a/src/power-bi/storage/Shared.Dataset/definition/tables/Disks.tmdl b/src/power-bi/storage/Shared.Dataset/definition/tables/Disks.tmdl new file mode 120000 index 000000000..e9f596dd5 --- /dev/null +++ b/src/power-bi/storage/Shared.Dataset/definition/tables/Disks.tmdl @@ -0,0 +1 @@ +../../../../kql/Shared.Dataset/definition/tables/Disks.tmdl \ No newline at end of file diff --git a/src/power-bi/storage/Shared.Dataset/definition/tables/ManagementGroups.tmdl b/src/power-bi/storage/Shared.Dataset/definition/tables/ManagementGroups.tmdl deleted file mode 100644 index 863e8e318..000000000 --- a/src/power-bi/storage/Shared.Dataset/definition/tables/ManagementGroups.tmdl +++ /dev/null @@ -1,154 +0,0 @@ -table ManagementGroups - lineageTag: 0e04ab5f-9838-4180-a7f3-dc1cbcb6f296 - - column id - dataType: string - lineageTag: 38577e5e-de2d-4ca7-a7bf-0bd1d7760f70 - summarizeBy: none - sourceColumn: id - - annotation SummarizationSetBy = Automatic - - column name - dataType: string - lineageTag: 0fd21169-a00f-4900-9617-2b610fd5aeeb - summarizeBy: none - sourceColumn: name - - annotation SummarizationSetBy = Automatic - - column 'properties.displayName' - dataType: string - lineageTag: c2a83af4-ecb0-48e2-8c91-c539f010c832 - summarizeBy: none - sourceColumn: properties.displayName - - annotation SummarizationSetBy = Automatic - - column 'properties.details' - dataType: string - lineageTag: 22995768-4815-4e93-8dbd-380eb7d44f43 - summarizeBy: none - sourceColumn: properties.details - - annotation SummarizationSetBy = Automatic - - column 'properties.details.managementGroupAncestorsChain' - dataType: string - lineageTag: d19480fb-6f16-49e7-b2b7-4fad83c35e7d - summarizeBy: none - sourceColumn: properties.details.managementGroupAncestorsChain - - annotation SummarizationSetBy = Automatic - - column 'properties.details.updatedTime' - dataType: string - lineageTag: 008e6ba3-287b-47b4-a4ab-739a14ac19fa - summarizeBy: none - sourceColumn: properties.details.updatedTime - - annotation SummarizationSetBy = Automatic - - column 'properties.details.updatedBy' - dataType: string - lineageTag: 7ba4276d-ba03-4243-b330-9b2961829e82 - summarizeBy: none - sourceColumn: properties.details.updatedBy - - annotation SummarizationSetBy = Automatic - - column 'properties.details.version' - dataType: string - lineageTag: cc74e405-4d3e-4c8f-b35f-2dd4d388b1d4 - summarizeBy: none - sourceColumn: properties.details.version - - annotation SummarizationSetBy = Automatic - - column 'properties.details.parent' - dataType: string - lineageTag: 107025bb-de26-4e8b-8c2a-64c244d292d8 - summarizeBy: none - sourceColumn: properties.details.parent - - annotation SummarizationSetBy = Automatic - - column 'properties.details.parent.displayName' - dataType: string - lineageTag: b160c643-8416-4ffd-a945-3c0119eafadb - summarizeBy: none - sourceColumn: properties.details.parent.displayName - - annotation SummarizationSetBy = Automatic - - column 'properties.details.parent.name' - dataType: string - lineageTag: e5cbe777-4e50-4c62-aec7-67ead1fe0b8d - summarizeBy: none - sourceColumn: properties.details.parent.name - - annotation SummarizationSetBy = Automatic - - column 'properties.details.parent.id' - dataType: string - lineageTag: 42790a1e-b547-4fdb-808f-8c49218e9530 - summarizeBy: none - sourceColumn: properties.details.parent.id - - annotation SummarizationSetBy = Automatic - - column 'properties.details.managementGroupAncestorsChain.displayName' - dataType: string - lineageTag: 4ca64703-7f49-4170-93f3-16087702156f - summarizeBy: none - sourceColumn: properties.details.managementGroupAncestorsChain.displayName - - annotation SummarizationSetBy = Automatic - - column 'properties.details.managementGroupAncestorsChain.name' - dataType: string - lineageTag: f5aa191d-ef68-4b44-92f7-63bdca6bc16c - summarizeBy: none - sourceColumn: properties.details.managementGroupAncestorsChain.name - - annotation SummarizationSetBy = Automatic - - partition ManagementGroups = m - mode: import - queryGroup: 'Resource Graph' - source = - let - query = " - resourcecontainers - | where type == 'microsoft.management/managementgroups' - | extend - ['properties.displayName'] = properties.displayName, - ['properties.details'] = properties.details, - ['properties.details.managementGroupAncestorsChain'] = properties.details.managementGroupAncestorsChain, - ['properties.details.updatedTime'] = properties.details.updatedTime, - ['properties.details.updatedBy'] = properties.details.updatedBy, - ['properties.details.version'] = properties.details.version, - ['properties.details.parent'] = properties.details.parent, - ['properties.details.parent.displayName'] = properties.details.parent.displayName, - ['properties.details.parent.name'] = properties.details.parent.name, - ['properties.details.parent.id'] = properties.details.parent.id - | mv-expand ['properties.details.managementGroupAncestorsChain'] - | extend - ['properties.details.managementGroupAncestorsChain.displayName'] = properties.details.managementGroupAncestorsChain.displayName, - ['properties.details.managementGroupAncestorsChain.name'] = properties.details.managementGroupAncestorsChain.name - " & (if ftk_DemoFilter() = "" then "" else "| where name startswith 'Trey'"), - Source = AzureResourceGraph.Query(query, "Tenant", null, null, [resultTruncated = false]), - NullHandling = - if Table.HasColumns(Source, "Results") and Table.RowCount(Source) = 1 then - #table( - { "id", "name", "properties.displayName", "properties.details", "properties.details.managementGroupAncestorsChain", "properties.details.updatedTime", "properties.details.updatedBy", "properties.details.version", "properties.details.parent", "properties.details.parent.displayName", "properties.details.parent.name", "properties.details.parent.id", "properties.details.managementGroupAncestorsChain.displayName", "properties.details.managementGroupAncestorsChain.name" }, - {} - ) - else Source - in - NullHandling - - annotation PBI_NavigationStepName = Navigation - - annotation PBI_ResultType = Table - diff --git a/src/power-bi/storage/Shared.Dataset/definition/tables/ManagementGroups.tmdl b/src/power-bi/storage/Shared.Dataset/definition/tables/ManagementGroups.tmdl new file mode 120000 index 000000000..c71c89f67 --- /dev/null +++ b/src/power-bi/storage/Shared.Dataset/definition/tables/ManagementGroups.tmdl @@ -0,0 +1 @@ +../../../../kql/Shared.Dataset/definition/tables/ManagementGroups.tmdl \ No newline at end of file diff --git a/src/power-bi/storage/Shared.Dataset/definition/tables/NetworkInterfaces.tmdl b/src/power-bi/storage/Shared.Dataset/definition/tables/NetworkInterfaces.tmdl deleted file mode 100644 index b10885ef7..000000000 --- a/src/power-bi/storage/Shared.Dataset/definition/tables/NetworkInterfaces.tmdl +++ /dev/null @@ -1,359 +0,0 @@ -table NetworkInterfaces - lineageTag: 471a2007-5388-404a-97e6-1b2292878a8c - - column id - dataType: string - lineageTag: 350304ea-658e-45c9-b91f-9a5c4e9e4e5e - summarizeBy: none - sourceColumn: id - - annotation SummarizationSetBy = Automatic - - column name - dataType: string - lineageTag: 4de0f771-a5db-454d-8359-25ac021b7c34 - summarizeBy: none - sourceColumn: name - - annotation SummarizationSetBy = Automatic - - column 'properties.provisioningState' - dataType: string - lineageTag: a914b230-a579-49f5-8d62-30f53d413472 - summarizeBy: none - sourceColumn: properties.provisioningState - - annotation SummarizationSetBy = Automatic - - column 'properties.resourceGuid' - dataType: string - lineageTag: f45d5cde-7c8c-4569-912f-9c5e231564d8 - summarizeBy: none - sourceColumn: properties.resourceGuid - - annotation SummarizationSetBy = Automatic - - column 'properties.enableAcceleratedNetworking' - dataType: string - lineageTag: a1b2c147-76f7-4804-8957-16d7f697ff99 - summarizeBy: none - sourceColumn: properties.enableAcceleratedNetworking - - annotation SummarizationSetBy = Automatic - - column 'properties.disableTcpStateTracking' - dataType: string - lineageTag: b5d561af-b683-4af3-87fc-f7566cc5f8f9 - summarizeBy: none - sourceColumn: properties.disableTcpStateTracking - - annotation SummarizationSetBy = Automatic - - column 'properties.vnetEncryptionSupported' - dataType: string - lineageTag: 415ce3bd-0646-4e4a-b38a-fc9a45800ef9 - summarizeBy: none - sourceColumn: properties.vnetEncryptionSupported - - annotation SummarizationSetBy = Automatic - - column 'properties.networkSecurityGroup.id' - dataType: string - lineageTag: 54e23578-a933-447d-a1db-f96c9089063d - summarizeBy: none - sourceColumn: properties.networkSecurityGroup.id - - annotation SummarizationSetBy = Automatic - - column 'properties.ipConfigurations.type' - dataType: string - lineageTag: 414395a3-c718-4bc4-ac73-606db3b02953 - summarizeBy: none - sourceColumn: properties.ipConfigurations.type - - annotation SummarizationSetBy = Automatic - - column 'properties.ipConfigurations.name' - dataType: string - lineageTag: 9dce3e2f-9097-4437-a16e-d5f79f3d75a9 - summarizeBy: none - sourceColumn: properties.ipConfigurations.name - - annotation SummarizationSetBy = Automatic - - column 'properties.ipConfigurations.properties.provisioningState' - dataType: string - lineageTag: 59df08a7-16e3-4ae1-9ceb-8b0370af6dbd - summarizeBy: none - sourceColumn: properties.ipConfigurations.properties.provisioningState - - annotation SummarizationSetBy = Automatic - - column 'properties.ipConfigurations.properties.privateIPAddressVersion' - dataType: string - lineageTag: 73c9a30f-9d7d-40f3-b25c-469ba0479e72 - summarizeBy: none - sourceColumn: properties.ipConfigurations.properties.privateIPAddressVersion - - annotation SummarizationSetBy = Automatic - - column 'properties.ipConfigurations.properties.privateIPAllocationMethod' - dataType: string - lineageTag: b76aad6e-6023-4164-8a57-a70456ed9f03 - summarizeBy: none - sourceColumn: properties.ipConfigurations.properties.privateIPAllocationMethod - - annotation SummarizationSetBy = Automatic - - column 'properties.ipConfigurations.properties.subnet' - dataType: string - lineageTag: 80ef1a4a-cf6e-48fc-afc4-181e61360d1d - summarizeBy: none - sourceColumn: properties.ipConfigurations.properties.subnet - - annotation SummarizationSetBy = Automatic - - column 'properties.ipConfigurations.properties.privateIPAddress' - dataType: string - lineageTag: 8c504c90-132f-4223-a0ad-a4348a5ee790 - summarizeBy: none - sourceColumn: properties.ipConfigurations.properties.privateIPAddress - - annotation SummarizationSetBy = Automatic - - column 'properties.ipConfigurations.properties.primary' - dataType: string - lineageTag: a9cbfce3-bbdf-4db6-bbb1-d16afbc57117 - summarizeBy: none - sourceColumn: properties.ipConfigurations.properties.primary - - annotation SummarizationSetBy = Automatic - - column 'properties.ipConfigurations.properties.publicIPAddress.id' - dataType: string - lineageTag: 26bdae49-b2c1-4acc-908b-6bc01631c134 - summarizeBy: none - sourceColumn: properties.ipConfigurations.properties.publicIPAddress.id - - annotation SummarizationSetBy = Automatic - - column 'properties.ipConfigurations.id' - dataType: string - lineageTag: 3c77c9cd-7a20-43f1-ad5f-4f57755e0f79 - summarizeBy: none - sourceColumn: properties.ipConfigurations.id - - annotation SummarizationSetBy = Automatic - - column 'properties.ipConfigurations.etag' - dataType: string - lineageTag: 95127943-55d6-4d40-9386-2bde61c45455 - summarizeBy: none - sourceColumn: properties.ipConfigurations.etag - - annotation SummarizationSetBy = Automatic - - column 'properties.enableIPForwarding' - dataType: string - lineageTag: 8c870b92-2431-48ed-a4e3-8adc3977625a - summarizeBy: none - sourceColumn: properties.enableIPForwarding - - annotation SummarizationSetBy = Automatic - - column 'properties.tapConfigurations' - dataType: string - lineageTag: 23417d1a-820a-4832-94a8-fa7097c30863 - summarizeBy: none - sourceColumn: properties.tapConfigurations - - annotation SummarizationSetBy = Automatic - - column 'properties.hostedWorkloads' - dataType: string - lineageTag: 69ad895c-4bb9-4f98-8da3-6c0b8a00d4f0 - summarizeBy: none - sourceColumn: properties.hostedWorkloads - - annotation SummarizationSetBy = Automatic - - column 'properties.allowPort25Out' - dataType: string - lineageTag: e9b92dd1-0da9-4db1-82db-1437b06af481 - summarizeBy: none - sourceColumn: properties.allowPort25Out - - annotation SummarizationSetBy = Automatic - - column 'properties.auxiliaryMode' - dataType: string - lineageTag: b3a8fb34-de86-48b2-bcc2-4602912fa4ac - summarizeBy: none - sourceColumn: properties.auxiliaryMode - - annotation SummarizationSetBy = Automatic - - column 'properties.dnsSettings' - dataType: string - lineageTag: 02f4ca50-b2c4-4c58-9349-dbc5f64cff51 - summarizeBy: none - sourceColumn: properties.dnsSettings - - annotation SummarizationSetBy = Automatic - - column 'properties.auxiliarySku' - dataType: string - lineageTag: 2b2a9e20-1b30-47e7-b827-de2d05b60924 - summarizeBy: none - sourceColumn: properties.auxiliarySku - - annotation SummarizationSetBy = Automatic - - column 'properties.macAddress' - dataType: string - lineageTag: ad7b0e74-c32a-46be-9b70-707bfc821aa1 - summarizeBy: none - sourceColumn: properties.macAddress - - annotation SummarizationSetBy = Automatic - - column 'properties.nicType' - dataType: string - lineageTag: b80d3831-5768-43c2-96a8-b9c7e02cb784 - summarizeBy: none - sourceColumn: properties.nicType - - annotation SummarizationSetBy = Automatic - - column 'properties.primary' - dataType: string - lineageTag: 17232334-69c8-41d2-8f26-2c29dbba06a3 - summarizeBy: none - sourceColumn: properties.primary - - annotation SummarizationSetBy = Automatic - - column 'properties.virtualMachine.id' - dataType: string - lineageTag: 04875637-be0f-43c8-8cef-9c1acc492ffc - summarizeBy: none - sourceColumn: properties.virtualMachine.id - - annotation SummarizationSetBy = Automatic - - column 'properties.networkSecurityGroup' - dataType: string - lineageTag: 8ff1ceae-7275-4140-97ff-2b5966d113ee - summarizeBy: none - sourceColumn: properties.networkSecurityGroup - - annotation SummarizationSetBy = Automatic - - column 'properties.ipConfigurations' - dataType: string - lineageTag: 5b7294e2-2846-4688-91ba-a7de264bad07 - summarizeBy: none - sourceColumn: properties.ipConfigurations - - annotation SummarizationSetBy = Automatic - - column 'properties.virtualMachine' - dataType: string - lineageTag: 6223842f-24da-46ce-8346-627044237497 - summarizeBy: none - sourceColumn: properties.virtualMachine - - annotation SummarizationSetBy = Automatic - - column 'properties.ipConfigurations.properties' - dataType: string - lineageTag: 961de273-fb7c-4805-8df8-0f6a1ddb345b - summarizeBy: none - sourceColumn: properties.ipConfigurations.properties - - annotation SummarizationSetBy = Automatic - - column 'properties.ipConfigurations.properties.publicIPAddress' - dataType: string - lineageTag: 0481ca01-dae9-474b-8233-501ab1bfe9ef - summarizeBy: none - sourceColumn: properties.ipConfigurations.properties.publicIPAddress - - annotation SummarizationSetBy = Automatic - - column location - dataType: string - lineageTag: 35f54cb8-f055-4a0c-a6d8-cb01f12f208a - summarizeBy: none - sourceColumn: location - - annotation SummarizationSetBy = Automatic - - column resourceGroup - dataType: string - lineageTag: a9f30217-df47-45f3-9392-92af1949fae6 - summarizeBy: none - sourceColumn: resourceGroup - - annotation SummarizationSetBy = Automatic - - partition NetworkInterfaces = m - mode: import - queryGroup: 'Resource Graph' - source = - let - query = " - Resources - | where type =~ 'microsoft.network/networkinterfaces' - | extend - ['properties.provisioningState'] = properties.provisioningState, - ['properties.resourceGuid'] = properties.resourceGuid, - ['properties.enableAcceleratedNetworking'] = properties.enableAcceleratedNetworking, - ['properties.disableTcpStateTracking'] = properties.disableTcpStateTracking, - ['properties.vnetEncryptionSupported'] = properties.vnetEncryptionSupported, - ['properties.networkSecurityGroup'] = properties.networkSecurityGroup, - ['properties.ipConfigurations'] = properties.ipConfigurations, - ['properties.enableIPForwarding'] = properties.enableIPForwarding, - ['properties.tapConfigurations'] = properties.tapConfigurations, - ['properties.hostedWorkloads'] = properties.hostedWorkloads, - ['properties.allowPort25Out'] = properties.allowPort25Out, - ['properties.auxiliaryMode'] = properties.auxiliaryMode, - ['properties.dnsSettings'] = properties.dnsSettings, - ['properties.auxiliarySku'] = properties.auxiliarySku, - ['properties.macAddress'] = properties.macAddress, - ['properties.nicType'] = properties.nicType, - ['properties.primary'] = properties.primary, - ['properties.virtualMachine'] = properties.virtualMachine, - ['properties.virtualMachine.id'] = properties.virtualMachine.id - | mv-expand ['properties.ipConfigurations'] - | extend - ['properties.ipConfigurations.type'] = properties.ipConfigurations.type, - ['properties.ipConfigurations.name'] = properties.ipConfigurations.name, - ['properties.ipConfigurations.properties'] = properties.ipConfigurations.properties, - ['properties.ipConfigurations.id'] = properties.ipConfigurations.id, - ['properties.ipConfigurations.etag'] = properties.ipConfigurations.etag, - ['properties.ipConfigurations.properties.provisioningState'] = properties.ipConfigurations.properties.provisioningState, - ['properties.ipConfigurations.properties.privateIPAddressVersion'] = properties.ipConfigurations.properties.privateIPAddressVersion, - ['properties.ipConfigurations.properties.privateIPAllocationMethod'] = properties.ipConfigurations.properties.privateIPAllocationMethod, - ['properties.ipConfigurations.properties.subnet'] = properties.ipConfigurations.properties.subnet, - ['properties.ipConfigurations.properties.privateIPAddress'] = properties.ipConfigurations.properties.privateIPAddress, - ['properties.ipConfigurations.properties.primary'] = properties.ipConfigurations.properties.primary, - ['properties.ipConfigurations.properties.publicIPAddress'] = properties.ipConfigurations.properties.publicIPAddress, - ['properties.ipConfigurations.properties.publicIPAddress.id'] = properties.ipConfigurations.properties.publicIPAddress.id, - ['properties.networkSecurityGroup.id'] = properties.networkSecurityGroup.id - " & ftk_DemoFilter(), - Source = AzureResourceGraph.Query(query, "Tenant", null, null, [resultTruncated = false]), - NullHandling = - if Table.HasColumns(Source, "Results") and Table.RowCount(Source) = 1 then - #table( - { "id", "name", "location", "resourceGroup", "properties.provisioningState", "properties.resourceGuid", "properties.enableAcceleratedNetworking", "properties.disableTcpStateTracking", "properties.vnetEncryptionSupported", "properties.networkSecurityGroup", "properties.ipConfigurations", "properties.enableIPForwarding", "properties.tapConfigurations", "properties.hostedWorkloads", "properties.allowPort25Out", "properties.auxiliaryMode", "properties.dnsSettings", "properties.auxiliarySku", "properties.macAddress", "properties.nicType", "properties.primary", "properties.virtualMachine", "properties.virtualMachine.id", "properties.ipConfigurations.type", "properties.ipConfigurations.name", "properties.ipConfigurations.properties", "properties.ipConfigurations.id", "properties.ipConfigurations.etag", "properties.ipConfigurations.properties.provisioningState", "properties.ipConfigurations.properties.privateIPAddressVersion", "properties.ipConfigurations.properties.privateIPAllocationMethod", "properties.ipConfigurations.properties.subnet", "properties.ipConfigurations.properties.privateIPAddress", "properties.ipConfigurations.properties.primary", "properties.ipConfigurations.properties.publicIPAddress", "properties.ipConfigurations.properties.publicIPAddress.id", "properties.networkSecurityGroup.id" }, - {} - ) - else Source - in - NullHandling - - annotation PBI_NavigationStepName = Navigation - - annotation PBI_ResultType = Table - diff --git a/src/power-bi/storage/Shared.Dataset/definition/tables/NetworkInterfaces.tmdl b/src/power-bi/storage/Shared.Dataset/definition/tables/NetworkInterfaces.tmdl new file mode 120000 index 000000000..8607c17a7 --- /dev/null +++ b/src/power-bi/storage/Shared.Dataset/definition/tables/NetworkInterfaces.tmdl @@ -0,0 +1 @@ +../../../../kql/Shared.Dataset/definition/tables/NetworkInterfaces.tmdl \ No newline at end of file diff --git a/src/power-bi/storage/Shared.Dataset/definition/tables/NetworkSecurityGroups.tmdl b/src/power-bi/storage/Shared.Dataset/definition/tables/NetworkSecurityGroups.tmdl deleted file mode 100644 index 4086e5283..000000000 --- a/src/power-bi/storage/Shared.Dataset/definition/tables/NetworkSecurityGroups.tmdl +++ /dev/null @@ -1,249 +0,0 @@ -table NetworkSecurityGroups - lineageTag: 7d98f967-9180-4a4f-958a-89256520af0f - - column id - dataType: string - lineageTag: f482c1e4-d36d-47dd-ab46-ab41d9e651ae - summarizeBy: none - sourceColumn: id - - annotation SummarizationSetBy = Automatic - - column name - dataType: string - lineageTag: dbe15cec-f5b3-4c38-8688-b1dc486c42d9 - summarizeBy: none - sourceColumn: name - - annotation SummarizationSetBy = Automatic - - column 'properties.resourceGuid' - dataType: string - lineageTag: eff5cb67-bada-4826-adc8-4b2a10f81ddc - summarizeBy: none - sourceColumn: properties.resourceGuid - - annotation SummarizationSetBy = Automatic - - column 'properties.securityRules.properties.destinationAddressPrefix' - dataType: string - lineageTag: 2f249b57-c790-4687-82a1-d805f75f3f83 - summarizeBy: none - sourceColumn: properties.securityRules.properties.destinationAddressPrefix - - annotation SummarizationSetBy = Automatic - - column 'properties.securityRules.properties.sourceAddressPrefix' - dataType: string - lineageTag: 04bad4dd-667f-4ff3-bde1-ad99b1b40d31 - summarizeBy: none - sourceColumn: properties.securityRules.properties.sourceAddressPrefix - - annotation SummarizationSetBy = Automatic - - column 'properties.securityRules.properties.destinationPortRange' - dataType: string - lineageTag: b2ca87a4-a342-493b-8a4e-8ae9b48755d0 - summarizeBy: none - sourceColumn: properties.securityRules.properties.destinationPortRange - - annotation SummarizationSetBy = Automatic - - column 'properties.securityRules.properties.sourcePortRange' - dataType: string - lineageTag: 77d6b680-9a1e-4e7f-8af8-13278f52c156 - summarizeBy: none - sourceColumn: properties.securityRules.properties.sourcePortRange - - annotation SummarizationSetBy = Automatic - - column 'properties.securityRules.properties.protocol' - dataType: string - lineageTag: 398c4c53-0c7b-4f52-a06a-e798d9df7416 - summarizeBy: none - sourceColumn: properties.securityRules.properties.protocol - - annotation SummarizationSetBy = Automatic - - column 'properties.securityRules.properties.direction' - dataType: string - lineageTag: 399c736a-57aa-4c0e-8892-865e1cef7484 - summarizeBy: none - sourceColumn: properties.securityRules.properties.direction - - annotation SummarizationSetBy = Automatic - - column 'properties.securityRules.properties.priority' - dataType: string - lineageTag: 437e410b-fa04-49ee-b33e-00abf7a5435d - summarizeBy: none - sourceColumn: properties.securityRules.properties.priority - - annotation SummarizationSetBy = Automatic - - column 'properties.securityRules.properties.access' - dataType: string - lineageTag: 5033a598-4e4b-4394-9085-3affe314aa9a - summarizeBy: none - sourceColumn: properties.securityRules.properties.access - - annotation SummarizationSetBy = Automatic - - column 'properties.securityRules.name' - dataType: string - lineageTag: 4c100028-a36b-4531-84fc-6b39ea2e005d - summarizeBy: none - sourceColumn: properties.securityRules.name - - annotation SummarizationSetBy = Automatic - - column 'properties.securityRules.id' - dataType: string - lineageTag: 710fb1a1-0b44-45c5-8e6b-e55ef2788b53 - summarizeBy: none - sourceColumn: properties.securityRules.id - - annotation SummarizationSetBy = Automatic - - column isWarning = ``` - IF('NetworkSecurityGroups'[properties.securityRules.properties.access]="Allow", - SWITCH( - 'NetworkSecurityGroups'[properties.securityRules.properties.destinationPortRange], - "80", "True", - "22", "True", - "3389", "True", - "False" - ), "False" - ) - ``` - lineageTag: 5fb590a3-057d-487e-af26-3e6686be93fe - summarizeBy: none - - annotation SummarizationSetBy = Automatic - - column 'properties.securityRules' - dataType: string - lineageTag: 49da77d4-1ae6-486d-8e0a-e05c49d44e91 - summarizeBy: none - sourceColumn: properties.securityRules - - annotation SummarizationSetBy = Automatic - - column location - dataType: string - lineageTag: 0df42dd6-3aa2-44f3-a2ad-b8556165582c - summarizeBy: none - sourceColumn: location - - annotation SummarizationSetBy = Automatic - - column resourceGroup - dataType: string - lineageTag: ee71f894-1abf-4b2a-8b79-1e7e73cc0db5 - summarizeBy: none - sourceColumn: resourceGroup - - annotation SummarizationSetBy = Automatic - - partition NetworkSecurityGroups = m - mode: import - queryGroup: 'Resource Graph' - source = - let - query = " - resources - | where type =~ 'microsoft.network/networksecuritygroups' - | extend - ['properties.resourceGuid'] = properties.resourceGuid, - ['properties.securityRules'] = properties.securityRules - | mv-expand ['properties.securityRules'] - | extend - ['properties.securityRules.name'] = properties.securityRules.name, - ['properties.securityRules.id'] = properties.securityRules.id, - ['properties.securityRules.properties.destinationAddressPrefix'] = properties.securityRules.properties.destinationAddressPrefix, - ['properties.securityRules.properties.sourceAddressPrefix'] = properties.securityRules.properties.sourceAddressPrefix, - ['properties.securityRules.properties.destinationPortRange'] = properties.securityRules.properties.destinationPortRange, - ['properties.securityRules.properties.sourcePortRange'] = properties.securityRules.properties.sourcePortRange, - ['properties.securityRules.properties.protocol'] = properties.securityRules.properties.protocol, - ['properties.securityRules.properties.direction'] = properties.securityRules.properties.direction, - ['properties.securityRules.properties.priority'] = properties.securityRules.properties.priority, - ['properties.securityRules.properties.access'] = properties.securityRules.properties.access - " & ftk_DemoFilter(), - Source = AzureResourceGraph.Query(query, "Tenant", null, null, [resultTruncated = false]), - NullHandling = - if Table.HasColumns(Source, "Results") and Table.RowCount(Source) = 1 then - #table( - { "id", "name", "location", "resourceGroup", "properties.resourceGuid", "properties.securityRules", "properties.securityRules.name", "properties.securityRules.id", "properties.securityRules.properties.destinationAddressPrefix", "properties.securityRules.properties.sourceAddressPrefix", "properties.securityRules.properties.destinationPortRange", "properties.securityRules.properties.sourcePortRange", "properties.securityRules.properties.protocol", "properties.securityRules.properties.direction", "properties.securityRules.properties.priority", "properties.securityRules.properties.access" }, - {} - ) - else Source - in - NullHandling - - - // Full query - // resources - // | where type =~ 'microsoft.network/networksecuritygroups' - // | extend - // ['properties.provisioningState'] = properties.provisioningState, - // ['properties.networkInterfaces'] = properties.networkInterfaces, - // ['properties.resourceGuid'] = properties.resourceGuid, - // ['properties.defaultSecurityRules'] = properties.defaultSecurityRules, - // ['properties.securityRules'] = properties.securityRules - // | mv-expand ['properties.networkInterfaces'] - // | extend - // ['properties.networkInterfaces.id'] = properties.networkInterfaces.id - // | mv-expand ['properties.defaultSecurityRules'] - // | extend - // ['properties.defaultSecurityRules.type'] = properties.defaultSecurityRules.type, - // ['properties.defaultSecurityRules.properties'] = properties.defaultSecurityRules.properties, - // ['properties.defaultSecurityRules.name'] = properties.defaultSecurityRules.name, - // ['properties.defaultSecurityRules.id'] = properties.defaultSecurityRules.id, - // ['properties.defaultSecurityRules.etag'] = properties.defaultSecurityRules.etag, - // ['properties.defaultSecurityRules.properties.provisioningState'] = properties.defaultSecurityRules.properties.provisioningState, - // ['properties.defaultSecurityRules.properties.destinationAddressPrefixes'] = properties.defaultSecurityRules.properties.destinationAddressPrefixes, - // ['properties.defaultSecurityRules.properties.destinationAddressPrefix'] = properties.defaultSecurityRules.properties.destinationAddressPrefix, - // ['properties.defaultSecurityRules.properties.destinationPortRanges'] = properties.defaultSecurityRules.properties.destinationPortRanges, - // ['properties.defaultSecurityRules.properties.sourceAddressPrefixes'] = properties.defaultSecurityRules.properties.sourceAddressPrefixes, - // ['properties.defaultSecurityRules.properties.sourceAddressPrefix'] = properties.defaultSecurityRules.properties.sourceAddressPrefix, - // ['properties.defaultSecurityRules.properties.destinationPortRange'] = properties.defaultSecurityRules.properties.destinationPortRange, - // ['properties.defaultSecurityRules.properties.sourcePortRanges'] = properties.defaultSecurityRules.properties.sourcePortRanges, - // ['properties.defaultSecurityRules.properties.sourcePortRange'] = properties.defaultSecurityRules.properties.sourcePortRange, - // ['properties.defaultSecurityRules.properties.description'] = properties.defaultSecurityRules.properties.description, - // ['properties.defaultSecurityRules.properties.protocol'] = properties.defaultSecurityRules.properties.protocol, - // ['properties.defaultSecurityRules.properties.direction'] = properties.defaultSecurityRules.properties.direction, - // ['properties.defaultSecurityRules.properties.priority'] = properties.defaultSecurityRules.properties.priority, - // ['properties.defaultSecurityRules.properties.access'] = properties.defaultSecurityRules.properties.access - // | mv-expand ['properties.defaultSecurityRules.properties.destinationAddressPrefixes'] - // | mv-expand ['properties.defaultSecurityRules.properties.destinationPortRanges'] - // | mv-expand ['properties.defaultSecurityRules.properties.sourceAddressPrefixes'] - // | mv-expand ['properties.defaultSecurityRules.properties.sourcePortRanges'] - // | mv-expand ['properties.securityRules'] - // | extend - // ['properties.securityRules.type'] = properties.securityRules.type, - // ['properties.securityRules.properties'] = properties.securityRules.properties, - // ['properties.securityRules.name'] = properties.securityRules.name, - // ['properties.securityRules.id'] = properties.securityRules.id, - // ['properties.securityRules.etag'] = properties.securityRules.etag, - // ['properties.securityRules.properties.provisioningState'] = properties.securityRules.properties.provisioningState, - // ['properties.securityRules.properties.destinationAddressPrefixes'] = properties.securityRules.properties.destinationAddressPrefixes, - // ['properties.securityRules.properties.destinationAddressPrefix'] = properties.securityRules.properties.destinationAddressPrefix, - // ['properties.securityRules.properties.destinationPortRanges'] = properties.securityRules.properties.destinationPortRanges, - // ['properties.securityRules.properties.sourceAddressPrefixes'] = properties.securityRules.properties.sourceAddressPrefixes, - // ['properties.securityRules.properties.sourceAddressPrefix'] = properties.securityRules.properties.sourceAddressPrefix, - // ['properties.securityRules.properties.destinationPortRange'] = properties.securityRules.properties.destinationPortRange, - // ['properties.securityRules.properties.sourcePortRanges'] = properties.securityRules.properties.sourcePortRanges, - // ['properties.securityRules.properties.sourcePortRange'] = properties.securityRules.properties.sourcePortRange, - // ['properties.securityRules.properties.protocol'] = properties.securityRules.properties.protocol, - // ['properties.securityRules.properties.direction'] = properties.securityRules.properties.direction, - // ['properties.securityRules.properties.priority'] = properties.securityRules.properties.priority, - // ['properties.securityRules.properties.access'] = properties.securityRules.properties.access - // | mv-expand ['properties.securityRules.properties.destinationAddressPrefixes'] - // | mv-expand ['properties.securityRules.properties.destinationPortRanges'] - // | mv-expand ['properties.securityRules.properties.sourceAddressPrefixes'] - // | mv-expand ['properties.securityRules.properties.sourcePortRanges'] - - annotation PBI_NavigationStepName = Navigation - - annotation PBI_ResultType = Table - diff --git a/src/power-bi/storage/Shared.Dataset/definition/tables/NetworkSecurityGroups.tmdl b/src/power-bi/storage/Shared.Dataset/definition/tables/NetworkSecurityGroups.tmdl new file mode 120000 index 000000000..7eb7d8f75 --- /dev/null +++ b/src/power-bi/storage/Shared.Dataset/definition/tables/NetworkSecurityGroups.tmdl @@ -0,0 +1 @@ +../../../../kql/Shared.Dataset/definition/tables/NetworkSecurityGroups.tmdl \ No newline at end of file diff --git a/src/power-bi/storage/Shared.Dataset/definition/tables/PolicyAssignments.tmdl b/src/power-bi/storage/Shared.Dataset/definition/tables/PolicyAssignments.tmdl deleted file mode 100644 index 23a204f7d..000000000 --- a/src/power-bi/storage/Shared.Dataset/definition/tables/PolicyAssignments.tmdl +++ /dev/null @@ -1,306 +0,0 @@ -table PolicyAssignments - lineageTag: fc42feb2-59a9-44bf-8459-e2c1592a05dd - - column id - dataType: string - lineageTag: 1d348226-a506-40a1-8192-5ec485e0af9e - summarizeBy: none - sourceColumn: id - - annotation SummarizationSetBy = Automatic - - column name - dataType: string - lineageTag: ff261d9a-3eef-498a-8636-ff52bf63770c - summarizeBy: none - sourceColumn: name - - annotation SummarizationSetBy = Automatic - - column 'properties.policyDefinitionId' - dataType: string - lineageTag: 36991dc9-f91b-42b4-9748-be127108cfde - summarizeBy: none - sourceColumn: properties.policyDefinitionId - - annotation SummarizationSetBy = Automatic - - column 'properties.effectiveDefinitionVersion' - dataType: string - lineageTag: 16da8ecd-c393-4286-a7cd-1040228789be - summarizeBy: none - sourceColumn: properties.effectiveDefinitionVersion - - annotation SummarizationSetBy = Automatic - - column 'properties.latestDefinitionVersion' - dataType: string - lineageTag: 3bca024d-238d-4d9b-bbb0-d684521dd31d - summarizeBy: none - sourceColumn: properties.latestDefinitionVersion - - annotation SummarizationSetBy = Automatic - - column 'properties.nonComplianceMessages' - dataType: string - lineageTag: 57b279a8-b3c2-4044-9e04-de1cc0c6164a - summarizeBy: none - sourceColumn: properties.nonComplianceMessages - - annotation SummarizationSetBy = Automatic - - column 'properties.definitionVersion' - dataType: string - lineageTag: 9aebe9eb-2371-4b13-9c76-36b3c5c823d6 - summarizeBy: none - sourceColumn: properties.definitionVersion - - annotation SummarizationSetBy = Automatic - - column 'properties.resourceSelectors' - dataType: string - lineageTag: 11813bfd-1f37-488d-9285-1e772849b256 - summarizeBy: none - sourceColumn: properties.resourceSelectors - - annotation SummarizationSetBy = Automatic - - column 'properties.enforcementMode' - dataType: string - lineageTag: d4584d1e-b6da-4040-b6a4-7134c0672510 - summarizeBy: none - sourceColumn: properties.enforcementMode - - annotation SummarizationSetBy = Automatic - - column 'properties.assignmentType' - dataType: string - lineageTag: 6819787b-73a8-4e0e-8070-023568c7b976 - summarizeBy: none - sourceColumn: properties.assignmentType - - annotation SummarizationSetBy = Automatic - - column 'properties.description' - dataType: string - lineageTag: d3ea744d-704e-48ee-9c5a-d8a17344916d - summarizeBy: none - sourceColumn: properties.description - - annotation SummarizationSetBy = Automatic - - column 'properties.displayName' - dataType: string - lineageTag: 5c957d8e-fd18-4850-960e-be9a8af7bccd - summarizeBy: none - sourceColumn: properties.displayName - - annotation SummarizationSetBy = Automatic - - column 'properties.parameters' - dataType: string - lineageTag: 1b67137d-df28-4b74-8513-486851b8628f - summarizeBy: none - sourceColumn: properties.parameters - - annotation SummarizationSetBy = Automatic - - column 'properties.notScopes' - dataType: string - lineageTag: e804ae45-625e-44c0-b9b7-faab55df20fc - summarizeBy: none - sourceColumn: properties.notScopes - - annotation SummarizationSetBy = Automatic - - column 'properties.overrides' - dataType: string - lineageTag: 1d20ddb9-f2f3-41d2-9449-dfea4797fb7f - summarizeBy: none - sourceColumn: properties.overrides - - annotation SummarizationSetBy = Automatic - - column 'properties.metadata.createdOn' - dataType: string - lineageTag: c2e66679-d4aa-440f-b152-d5d57460bea8 - summarizeBy: none - sourceColumn: properties.metadata.createdOn - - annotation SummarizationSetBy = Automatic - - column 'properties.metadata.createdBy' - dataType: string - lineageTag: 9b40d28e-65b2-4ae1-92b1-7f60becaf430 - summarizeBy: none - sourceColumn: properties.metadata.createdBy - - annotation SummarizationSetBy = Automatic - - column 'properties.metadata.assignedBy' - dataType: string - lineageTag: 5f9f32b3-e881-4748-814c-30eec5c31a6d - summarizeBy: none - sourceColumn: properties.metadata.assignedBy - - annotation SummarizationSetBy = Automatic - - column 'properties.metadata.parameterScopes' - dataType: string - lineageTag: cd98c09d-2563-4c18-b3ab-8843c0ec89fa - summarizeBy: none - sourceColumn: properties.metadata.parameterScopes - - annotation SummarizationSetBy = Automatic - - column 'properties.metadata.updatedOn' - dataType: string - lineageTag: 2a9a3ec7-6033-442b-95dd-ca16a8aa1a58 - summarizeBy: none - sourceColumn: properties.metadata.updatedOn - - annotation SummarizationSetBy = Automatic - - column 'properties.metadata.updatedBy' - dataType: string - lineageTag: eff9fd70-f125-4e24-af7f-00c272ad7bd4 - summarizeBy: none - sourceColumn: properties.metadata.updatedBy - - annotation SummarizationSetBy = Automatic - - column 'properties.metadata.category' - dataType: string - lineageTag: 359d4829-4b57-4c18-867f-175a3b77dfc9 - summarizeBy: none - sourceColumn: properties.metadata.category - - annotation SummarizationSetBy = Automatic - - column 'properties.metadata.managedByResourceId' - dataType: string - lineageTag: c1974d8c-1e1f-429c-802c-ef88431e904a - summarizeBy: none - sourceColumn: properties.metadata.managedByResourceId - - annotation SummarizationSetBy = Automatic - - column 'properties.metadata.securityCenter' - dataType: string - lineageTag: 314cbab7-3be5-4e85-9d9f-9fe808ccc0be - summarizeBy: none - sourceColumn: properties.metadata.securityCenter - - annotation SummarizationSetBy = Automatic - - column 'properties.metadata.excludedOutOfTheBoxStandards' - dataType: string - lineageTag: 01fd1c38-2a24-4858-9335-8bd5cfdab130 - summarizeBy: none - sourceColumn: properties.metadata.excludedOutOfTheBoxStandards - - annotation SummarizationSetBy = Automatic - - column 'properties.scope' - dataType: string - lineageTag: 445e8666-eaf2-4846-8f0f-439c5f6bf9da - summarizeBy: none - sourceColumn: properties.scope - - annotation SummarizationSetBy = Automatic - - column 'identity.userAssignedIdentities' - dataType: string - lineageTag: 8586946a-0e29-4772-b707-275f248a986b - summarizeBy: none - sourceColumn: identity.userAssignedIdentities - - annotation SummarizationSetBy = Automatic - - column 'identity.principalId' - dataType: string - lineageTag: c41ce4d0-bbea-4b58-b2d9-31d310c82775 - summarizeBy: none - sourceColumn: identity.principalId - - annotation SummarizationSetBy = Automatic - - column 'identity.tenantId' - dataType: string - lineageTag: 3c44bc44-86b1-4fc9-af7b-0d1c0c80a39f - summarizeBy: none - sourceColumn: identity.tenantId - - annotation SummarizationSetBy = Automatic - - column 'identity.type' - dataType: string - lineageTag: ab440e5d-da40-4376-8be6-ddae6a99cb27 - summarizeBy: none - sourceColumn: identity.type - - annotation SummarizationSetBy = Automatic - - column 'properties.metadata' - dataType: string - lineageTag: a94cc1c6-bf08-40f6-91b4-5ce811d3b876 - summarizeBy: none - sourceColumn: properties.metadata - - annotation SummarizationSetBy = Automatic - - partition PolicyAssignments = m - mode: import - queryGroup: 'Resource Graph' - source = - let - query = " - policyResources - | where type =~'Microsoft.Authorization/PolicyAssignments' - | extend - ['properties.policyDefinitionId'] = properties.policyDefinitionId, - ['properties.effectiveDefinitionVersion'] = properties.effectiveDefinitionVersion, - ['properties.latestDefinitionVersion'] = properties.latestDefinitionVersion, - ['properties.nonComplianceMessages'] = properties.nonComplianceMessages, - ['properties.definitionVersion'] = properties.definitionVersion, - ['properties.resourceSelectors'] = properties.resourceSelectors, - ['properties.enforcementMode'] = properties.enforcementMode, - ['properties.assignmentType'] = properties.assignmentType, - ['properties.description'] = properties.description, - ['properties.displayName'] = properties.displayName, - ['properties.parameters'] = properties.parameters, - ['properties.notScopes'] = properties.notScopes, - ['properties.overrides'] = properties.overrides, - ['properties.metadata'] = properties.metadata, - ['properties.scope'] = properties.scope, - ['properties.metadata.createdOn'] = properties.metadata.createdOn, - ['properties.metadata.createdBy'] = properties.metadata.createdBy, - ['properties.metadata.assignedBy'] = properties.metadata.assignedBy, - ['properties.metadata.parameterScopes'] = properties.metadata.parameterScopes, - ['properties.metadata.updatedOn'] = properties.metadata.updatedOn, - ['properties.metadata.updatedBy'] = properties.metadata.updatedBy, - ['properties.metadata.category'] = properties.metadata.category, - ['properties.metadata.managedByResourceId'] = properties.metadata.managedByResourceId, - ['properties.metadata.securityCenter'] = properties.metadata.securityCenter, - ['properties.metadata.excludedOutOfTheBoxStandards'] = properties.metadata.excludedOutOfTheBoxStandards, - ['identity.userAssignedIdentities'] = identity.userAssignedIdentities, - ['identity.principalId'] = identity.principalId, - ['identity.tenantId'] = identity.tenantId, - ['identity.type'] = identity.type - | mv-expand ['properties.notScopes'] - " & ftk_DemoFilter(), - Source = AzureResourceGraph.Query(query, "Tenant", null, null, [resultTruncated = false]), - NullHandling = - if Table.HasColumns(Source, "Results") and Table.RowCount(Source) = 1 then - #table( - { "id", "name", "properties.policyDefinitionId", "properties.effectiveDefinitionVersion", "properties.latestDefinitionVersion", "properties.nonComplianceMessages", "properties.definitionVersion", "properties.resourceSelectors", "properties.enforcementMode", "properties.assignmentType", "properties.description", "properties.displayName", "properties.parameters", "properties.notScopes", "properties.overrides", "properties.metadata", "properties.scope", "properties.metadata.createdOn", "properties.metadata.createdBy", "properties.metadata.assignedBy", "properties.metadata.parameterScopes", "properties.metadata.updatedOn", "properties.metadata.updatedBy", "properties.metadata.category", "properties.metadata.managedByResourceId", "properties.metadata.securityCenter", "properties.metadata.excludedOutOfTheBoxStandards", "identity.userAssignedIdentities", "identity.principalId", "identity.tenantId", "identity.type" }, - {} - ) - else Source - in - NullHandling - - annotation PBI_NavigationStepName = Navigation - - annotation PBI_ResultType = Table - diff --git a/src/power-bi/storage/Shared.Dataset/definition/tables/PolicyAssignments.tmdl b/src/power-bi/storage/Shared.Dataset/definition/tables/PolicyAssignments.tmdl new file mode 120000 index 000000000..b745e0ec1 --- /dev/null +++ b/src/power-bi/storage/Shared.Dataset/definition/tables/PolicyAssignments.tmdl @@ -0,0 +1 @@ +../../../../kql/Shared.Dataset/definition/tables/PolicyAssignments.tmdl \ No newline at end of file diff --git a/src/power-bi/storage/Shared.Dataset/definition/tables/PolicyStates.tmdl b/src/power-bi/storage/Shared.Dataset/definition/tables/PolicyStates.tmdl deleted file mode 100644 index 1ef43f326..000000000 --- a/src/power-bi/storage/Shared.Dataset/definition/tables/PolicyStates.tmdl +++ /dev/null @@ -1,276 +0,0 @@ -table PolicyStates - lineageTag: cf0e7752-0e35-40aa-a509-8a4f90194eee - - measure complianceScore = [compliantCount]/[totalResourceCount] - formatString: 0.00\ %;-0.00\ %;0.00\ % - lineageTag: 8ef15317-240f-47a3-b0c2-fa0d092eda61 - - measure compliantCount = [totalResourceCount]-[nonCompliantCount] - lineageTag: 29316f3a-f1eb-4c74-9f1b-a5b5534a8439 - - measure nonCompliantCount = CALCULATE(DISTINCTCOUNT(PolicyStates[properties.resourceId]),FILTER(PolicyStates,PolicyStates[properties.complianceState]="NonCompliant")) - formatString: 0 - lineageTag: c25950a1-8a49-4e9e-9d81-0a5972981c83 - - measure totalResourceCount = DISTINCTCOUNT(PolicyStates[properties.resourceId]) - formatString: 0 - lineageTag: b2e3060a-ed8b-4a7f-bf4e-171701a5e3d6 - - column id - dataType: string - lineageTag: d4561592-c509-4be1-b385-54bd35c5ec64 - summarizeBy: none - sourceColumn: id - - annotation SummarizationSetBy = Automatic - - column name - dataType: string - lineageTag: 2df63a8b-89fb-4025-b249-7966450656e0 - summarizeBy: none - sourceColumn: name - - annotation SummarizationSetBy = Automatic - - column 'properties.policyAssignmentParameters' - dataType: string - lineageTag: 783fc75e-393f-420a-b8ee-2646799d9089 - summarizeBy: none - sourceColumn: properties.policyAssignmentParameters - - annotation SummarizationSetBy = Automatic - - column 'properties.policyDefinitionAction' - dataType: string - lineageTag: 58ea97b8-2c5d-43a7-98ea-3e0951ec4dfc - summarizeBy: none - sourceColumn: properties.policyDefinitionAction - - annotation SummarizationSetBy = Automatic - - column 'properties.policyAssignmentScope' - dataType: string - lineageTag: f665182c-f54e-4c40-977c-561dd6faa46d - summarizeBy: none - sourceColumn: properties.policyAssignmentScope - - annotation SummarizationSetBy = Automatic - - column 'properties.policyAssignmentName' - dataType: string - lineageTag: 3df25eec-090a-4c1b-a852-69054f56dfdd - summarizeBy: none - sourceColumn: properties.policyAssignmentName - - annotation SummarizationSetBy = Automatic - - column 'properties.policyDefinitionName' - dataType: string - lineageTag: 67350a21-f5cc-43c1-92ed-064bb00320ac - summarizeBy: none - sourceColumn: properties.policyDefinitionName - - annotation SummarizationSetBy = Automatic - - column 'properties.policyDefinitionReferenceId' - dataType: string - lineageTag: 3c524d4a-60f0-4a4d-8a5b-1123317b7096 - summarizeBy: none - sourceColumn: properties.policyDefinitionReferenceId - - annotation SummarizationSetBy = Automatic - - column 'properties.policyDefinitionId' - dataType: string - lineageTag: f0d2244b-93f7-481e-9de9-c3dc6d894ea8 - summarizeBy: none - sourceColumn: properties.policyDefinitionId - - annotation SummarizationSetBy = Automatic - - column 'properties.managementGroupIds' - dataType: string - lineageTag: 720d2a55-2591-4d1d-a162-6a2c3b0c1061 - summarizeBy: none - sourceColumn: properties.managementGroupIds - - annotation SummarizationSetBy = Automatic - - column 'properties.policyAssignmentId' - dataType: string - lineageTag: 77528366-57af-4541-b8d9-034cbfdfd50a - summarizeBy: none - sourceColumn: properties.policyAssignmentId - - annotation SummarizationSetBy = Automatic - - column 'properties.policySetDefinitionName' - dataType: string - lineageTag: ff358f4c-5504-4c56-a883-53d4e636b71e - summarizeBy: none - sourceColumn: properties.policySetDefinitionName - - annotation SummarizationSetBy = Automatic - - column 'properties.complianceState' - dataType: string - lineageTag: 5ab6c2e6-763a-412b-960f-cfb43ddeb748 - summarizeBy: none - sourceColumn: properties.complianceState - - annotation SummarizationSetBy = Automatic - - column 'properties.policySetDefinitionId' - dataType: string - lineageTag: e8f24c7c-ea8a-46b7-a73d-1fa68f22bc92 - summarizeBy: none - sourceColumn: properties.policySetDefinitionId - - annotation SummarizationSetBy = Automatic - - column 'properties.subscriptionId' - dataType: string - lineageTag: 6ff5f7b7-6409-4422-9836-e62d383cc34a - summarizeBy: none - sourceColumn: properties.subscriptionId - - annotation SummarizationSetBy = Automatic - - column 'properties.resourceType' - dataType: string - lineageTag: b1d49f84-9b69-4118-9235-cde3c949457c - summarizeBy: none - sourceColumn: properties.resourceType - - annotation SummarizationSetBy = Automatic - - column 'properties.stateWeight' - dataType: string - lineageTag: 5c6c27a9-5ef9-492a-af89-ec2e7de56e3c - summarizeBy: none - sourceColumn: properties.stateWeight - - annotation SummarizationSetBy = Automatic - - column 'properties.resourceGroup' - dataType: string - lineageTag: bab7846a-e342-4472-82db-587b700c3e03 - summarizeBy: none - sourceColumn: properties.resourceGroup - - annotation SummarizationSetBy = Automatic - - column 'properties.resourceId' - dataType: string - lineageTag: be95d463-c31e-472e-b7a9-ce79a87886c5 - summarizeBy: none - sourceColumn: properties.resourceId - - annotation SummarizationSetBy = Automatic - - column 'properties.timestamp' - dataType: string - lineageTag: f3d23e6e-ccdb-4149-8f8e-87df9ec51a6c - summarizeBy: none - sourceColumn: properties.timestamp - - annotation SummarizationSetBy = Automatic - - column 'properties.isDeleted' - dataType: string - lineageTag: 8b13dbc1-fda0-4464-9c8f-543d1fa99f9a - summarizeBy: none - sourceColumn: properties.isDeleted - - annotation SummarizationSetBy = Automatic - - column 'properties.resourceLocation' - dataType: string - lineageTag: 7face71a-1084-448e-9448-fdbd851a4a73 - summarizeBy: none - sourceColumn: properties.resourceLocation - - annotation SummarizationSetBy = Automatic - - column 'properties.policySetDefinitionCategory' - dataType: string - lineageTag: 2821fa37-31e7-49c4-983d-e097cc4ac6b3 - summarizeBy: none - sourceColumn: properties.policySetDefinitionCategory - - annotation SummarizationSetBy = Automatic - - column 'properties.policyDefinitionGroupNames' - dataType: string - lineageTag: 5b1f343c-d014-4884-976f-078ec25e7432 - summarizeBy: none - sourceColumn: properties.policyDefinitionGroupNames - - annotation SummarizationSetBy = Automatic - - column 'properties.complianceReasonCode' - dataType: string - lineageTag: d7426779-4a22-4013-8dbd-65b45b3fc3d1 - summarizeBy: none - sourceColumn: properties.complianceReasonCode - - annotation SummarizationSetBy = Automatic - - column 'properties.stateDetails' - dataType: string - lineageTag: b29f486c-994e-4218-8b7f-d4b4421a54b8 - summarizeBy: none - sourceColumn: properties.stateDetails - - annotation SummarizationSetBy = Automatic - - partition PolicyStates = m - mode: import - queryGroup: 'Resource Graph' - source = - let - query = " - policyResources - | where type =~'Microsoft.PolicyInsights/PolicyStates' - | extend - ['properties.policyAssignmentParameters'] = properties.policyAssignmentParameters, - ['properties.policyDefinitionAction'] = properties.policyDefinitionAction, - ['properties.policyAssignmentScope'] = properties.policyAssignmentScope, - ['properties.policyAssignmentName'] = properties.policyAssignmentName, - ['properties.policyDefinitionName'] = properties.policyDefinitionName, - ['properties.policyDefinitionReferenceId'] = properties.policyDefinitionReferenceId, - ['properties.policyDefinitionId'] = properties.policyDefinitionId, - ['properties.managementGroupIds'] = properties.managementGroupIds, - ['properties.policyAssignmentId'] = properties.policyAssignmentId, - ['properties.policySetDefinitionName'] = properties.policySetDefinitionName, - ['properties.complianceState'] = properties.complianceState, - ['properties.policySetDefinitionId'] = properties.policySetDefinitionId, - ['properties.subscriptionId'] = properties.subscriptionId, - ['properties.resourceType'] = properties.resourceType, - ['properties.stateWeight'] = properties.stateWeight, - ['properties.resourceGroup'] = properties.resourceGroup, - ['properties.resourceId'] = properties.resourceId, - ['properties.timestamp'] = properties.timestamp, - ['properties.isDeleted'] = properties.isDeleted, - ['properties.resourceLocation'] = properties.resourceLocation, - ['properties.policySetDefinitionCategory'] = properties.policySetDefinitionCategory, - ['properties.policyDefinitionGroupNames'] = properties.policyDefinitionGroupNames, - ['properties.complianceReasonCode'] = properties.complianceReasonCode, - ['properties.stateDetails'] = properties.stateDetails - " & ftk_DemoFilter(), - Source = AzureResourceGraph.Query(query, "Tenant", null, null, [resultTruncated = false]), - NullHandling = - if Table.HasColumns(Source, "Results") and Table.RowCount(Source) = 1 then - #table( - { "id", "name", "properties.policyAssignmentParameters", "properties.policyDefinitionAction", "properties.policyAssignmentScope", "properties.policyAssignmentName", "properties.policyDefinitionName", "properties.policyDefinitionReferenceId", "properties.policyDefinitionId", "properties.managementGroupIds", "properties.policyAssignmentId", "properties.policySetDefinitionName", "properties.complianceState", "properties.policySetDefinitionId", "properties.subscriptionId", "properties.resourceType", "properties.stateWeight", "properties.resourceGroup", "properties.resourceId", "properties.timestamp", "properties.isDeleted", "properties.resourceLocation", "properties.policySetDefinitionCategory", "properties.policyDefinitionGroupNames", "properties.complianceReasonCode", "properties.stateDetails" }, - {} - ) - else Source, - Types = Table.TransformColumns(NullHandling, {{"properties.policyAssignmentScope", each Text.AfterDelimiter(_, "/", {0, RelativePosition.FromEnd}), type text}}, null, MissingField.Ignore) - in - Types - - annotation PBI_NavigationStepName = Navigation - - annotation PBI_ResultType = Table - diff --git a/src/power-bi/storage/Shared.Dataset/definition/tables/PolicyStates.tmdl b/src/power-bi/storage/Shared.Dataset/definition/tables/PolicyStates.tmdl new file mode 120000 index 000000000..879e3a9e3 --- /dev/null +++ b/src/power-bi/storage/Shared.Dataset/definition/tables/PolicyStates.tmdl @@ -0,0 +1 @@ +../../../../kql/Shared.Dataset/definition/tables/PolicyStates.tmdl \ No newline at end of file diff --git a/src/power-bi/storage/Shared.Dataset/definition/tables/PublicIPAddresses.tmdl b/src/power-bi/storage/Shared.Dataset/definition/tables/PublicIPAddresses.tmdl deleted file mode 100644 index ac2dd5755..000000000 --- a/src/power-bi/storage/Shared.Dataset/definition/tables/PublicIPAddresses.tmdl +++ /dev/null @@ -1,116 +0,0 @@ -table PublicIPAddresses - lineageTag: 5c35f59e-97dc-424c-b1ae-0526c2c708ed - - column id - dataType: string - lineageTag: 25bf5fbf-8f5e-4b15-a187-625c6a612325 - summarizeBy: none - sourceColumn: id - - annotation SummarizationSetBy = Automatic - - column name - dataType: string - lineageTag: 6004d8c7-c14e-4645-959a-be60b835cff9 - summarizeBy: none - sourceColumn: name - - annotation SummarizationSetBy = Automatic - - column 'properties.provisioningState' - dataType: string - lineageTag: 552b63bf-51c6-487b-94ba-9811897d6668 - summarizeBy: none - sourceColumn: properties.provisioningState - - annotation SummarizationSetBy = Automatic - - column 'properties.resourceGuid' - dataType: string - lineageTag: 9792e908-997a-4ef1-a288-cca086f0a720 - summarizeBy: none - sourceColumn: properties.resourceGuid - - annotation SummarizationSetBy = Automatic - - column 'properties.idleTimeoutInMinutes' - dataType: string - lineageTag: 71fa242f-feef-4749-871e-212257842c7c - summarizeBy: none - sourceColumn: properties.idleTimeoutInMinutes - - annotation SummarizationSetBy = Automatic - - column 'properties.publicIPAllocationMethod' - dataType: string - lineageTag: 6691799d-57f0-4949-b0cb-a3d392b056c0 - summarizeBy: none - sourceColumn: properties.publicIPAllocationMethod - - annotation SummarizationSetBy = Automatic - - column 'properties.publicIPAddressVersion' - dataType: string - lineageTag: a2509f77-55b5-4da7-bc2b-673da4224c5c - summarizeBy: none - sourceColumn: properties.publicIPAddressVersion - - annotation SummarizationSetBy = Automatic - - column 'properties.ipAddress' - dataType: string - lineageTag: c4667d70-08f9-4d7c-8401-1bb9674cdc65 - summarizeBy: none - sourceColumn: properties.ipAddress - - annotation SummarizationSetBy = Automatic - - column 'properties.ipConfiguration' - dataType: string - lineageTag: 996ada29-00db-4da9-8c3a-f132a9942293 - summarizeBy: none - sourceColumn: properties.ipConfiguration - - annotation SummarizationSetBy = Automatic - - column 'properties.ipTags' - dataType: string - lineageTag: c6048a40-80ce-40bf-85c2-5020bd678dee - summarizeBy: none - sourceColumn: properties.ipTags - - annotation SummarizationSetBy = Automatic - - partition PublicIPAddresses = m - mode: import - queryGroup: 'Resource Graph' - source = - let - query = " - Resources - | where type =~ 'microsoft.network/publicipaddresses' - | extend - ['properties.provisioningState'] = properties.provisioningState, - ['properties.resourceGuid'] = properties.resourceGuid, - ['properties.idleTimeoutInMinutes'] = properties.idleTimeoutInMinutes, - ['properties.publicIPAllocationMethod'] = properties.publicIPAllocationMethod, - ['properties.publicIPAddressVersion'] = properties.publicIPAddressVersion, - ['properties.ipAddress'] = properties.ipAddress, - ['properties.ipConfiguration'] = properties.ipConfiguration, - ['properties.ipTags'] = properties.ipTags - " & ftk_DemoFilter(), - Source = AzureResourceGraph.Query(query, "Tenant", null, null, [resultTruncated = false]), - NullHandling = - if Table.HasColumns(Source, "Results") and Table.RowCount(Source) = 1 then - #table( - { "id", "name", "properties.provisioningState", "properties.resourceGuid", "properties.idleTimeoutInMinutes", "properties.publicIPAllocationMethod", "properties.publicIPAddressVersion", "properties.ipAddress", "properties.ipConfiguration", "properties.ipTags" }, - {} - ) - else Source - in - NullHandling - - annotation PBI_NavigationStepName = Navigation - - annotation PBI_ResultType = Table - diff --git a/src/power-bi/storage/Shared.Dataset/definition/tables/PublicIPAddresses.tmdl b/src/power-bi/storage/Shared.Dataset/definition/tables/PublicIPAddresses.tmdl new file mode 120000 index 000000000..8fad22b99 --- /dev/null +++ b/src/power-bi/storage/Shared.Dataset/definition/tables/PublicIPAddresses.tmdl @@ -0,0 +1 @@ +../../../../kql/Shared.Dataset/definition/tables/PublicIPAddresses.tmdl \ No newline at end of file diff --git a/src/power-bi/storage/Shared.Dataset/definition/tables/Resources.tmdl b/src/power-bi/storage/Shared.Dataset/definition/tables/Resources.tmdl deleted file mode 100644 index a9b90a5df..000000000 --- a/src/power-bi/storage/Shared.Dataset/definition/tables/Resources.tmdl +++ /dev/null @@ -1,114 +0,0 @@ -table Resources - lineageTag: ec447c64-6e55-41d8-a5ea-a43adab5dc79 - - column id - dataType: string - lineageTag: 6c849866-bafa-4cdf-a863-0a5831052c26 - summarizeBy: none - sourceColumn: id - - annotation SummarizationSetBy = Automatic - - column name - dataType: string - lineageTag: d4a137b0-b83b-4750-8515-efc2bd5aecd0 - summarizeBy: none - sourceColumn: name - - annotation SummarizationSetBy = Automatic - - column type - dataType: string - lineageTag: 1b2381eb-97e7-4d28-90ab-21ca7571abeb - summarizeBy: none - sourceColumn: type - - annotation SummarizationSetBy = Automatic - - column tenantId - dataType: string - lineageTag: 22020c14-f82a-4ce1-91aa-258318ca95d5 - summarizeBy: none - sourceColumn: tenantId - - annotation SummarizationSetBy = Automatic - - column location - dataType: string - lineageTag: 94a3783c-937e-4fad-a7bd-7dc286027241 - summarizeBy: none - sourceColumn: location - - annotation SummarizationSetBy = Automatic - - column resourceGroup - dataType: string - lineageTag: bf7f9a12-8b99-43f1-bb81-7df06117afb8 - summarizeBy: none - sourceColumn: resourceGroup - - annotation SummarizationSetBy = Automatic - - column subscriptionId - dataType: string - lineageTag: 8c7bbeee-c26d-4a1c-9f17-1061d8e43724 - summarizeBy: none - sourceColumn: subscriptionId - - annotation SummarizationSetBy = Automatic - - column creationTime - dataType: string - lineageTag: 3313d128-8b39-4fe1-ba22-8e9f6dc24f42 - summarizeBy: none - sourceColumn: creationTime - - annotation SummarizationSetBy = Automatic - - column x_ResourceGroupId = "/subscriptions/" & Resources[subscriptionId] & "/resourcegroups/" & Resources[resourceGroup] - lineageTag: dfd516fd-8d25-441f-93a3-190abe05d572 - summarizeBy: none - - annotation SummarizationSetBy = Automatic - - column timeModified - dataType: string - lineageTag: f9a30d28-b76c-4f48-b909-ae980bbfbc27 - summarizeBy: none - sourceColumn: timeModified - - annotation SummarizationSetBy = Automatic - - partition Resources = m - mode: import - queryGroup: 'Resource Graph' - source = - let - query = " - resources - | extend - id = tolower(id), - ['creationTime'] = properties.creationTime, - ['timeModified'] = properties.timeModified - | project id, name, type, tenantId, location, subscriptionId, resourceGroup, creationTime, timeModified - " & ftk_DemoFilter(), - Source = AzureResourceGraph.Query(query, "Tenant", null, null, [resultTruncated = false]), - NullHandling = - if Table.HasColumns(Source, "Results") and Table.RowCount(Source) = 1 then - #table( - { "id", "name", "type", "tenantId", "location", "subscriptionId", "resourceGroup", "creationTime", "timeModified" }, - {} - ) - else Source, - - // Remove duplicate IDs - // This step may hide valid rows and show invalid rows due to a bug in Resource Graph. We do not recommend it but are including it in case you want to unblock yourself. - // If you experience a "duplicate IDs" error for the Resources table, please file a support request against Azure Resource Graph. - RemoveDuplicates = if #"Remove Duplicate Resource IDs" then Table.Distinct(NullHandling, {"id"}) else NullHandling - in - RemoveDuplicates - - annotation PBI_NavigationStepName = Navigation - - annotation PBI_ResultType = Table - diff --git a/src/power-bi/storage/Shared.Dataset/definition/tables/Resources.tmdl b/src/power-bi/storage/Shared.Dataset/definition/tables/Resources.tmdl new file mode 120000 index 000000000..a0cac40ed --- /dev/null +++ b/src/power-bi/storage/Shared.Dataset/definition/tables/Resources.tmdl @@ -0,0 +1 @@ +../../../../kql/Shared.Dataset/definition/tables/Resources.tmdl \ No newline at end of file diff --git a/src/power-bi/storage/Shared.Dataset/definition/tables/SqlDatabases.tmdl b/src/power-bi/storage/Shared.Dataset/definition/tables/SqlDatabases.tmdl deleted file mode 100644 index 077a26057..000000000 --- a/src/power-bi/storage/Shared.Dataset/definition/tables/SqlDatabases.tmdl +++ /dev/null @@ -1,287 +0,0 @@ -table SqlDatabases - lineageTag: 28ccb046-cb49-4d65-8bef-6c25b4e6d9bd - - column id - dataType: string - lineageTag: a62eaf23-4570-4604-84a8-62c1cc93732f - summarizeBy: none - sourceColumn: id - - annotation SummarizationSetBy = Automatic - - column name - dataType: string - lineageTag: b343c8ed-f905-49e3-a997-7993656a8edc - summarizeBy: none - sourceColumn: name - - annotation SummarizationSetBy = Automatic - - column 'sku.name' - dataType: string - lineageTag: 1be92f30-01fc-4f24-b3f1-7f6321288452 - summarizeBy: none - sourceColumn: sku.name - - annotation SummarizationSetBy = Automatic - - column 'sku.tier' - dataType: string - lineageTag: 1055f96a-796e-4fdd-92c4-d82dfe695486 - summarizeBy: none - sourceColumn: sku.tier - - annotation SummarizationSetBy = Automatic - - column 'sku.capacity' - dataType: string - lineageTag: 043c12dd-1962-4a4b-ae15-28f6dcceb173 - summarizeBy: none - sourceColumn: sku.capacity - - annotation SummarizationSetBy = Automatic - - column 'sku.family' - dataType: string - lineageTag: dc9ae49c-72fb-4f17-8dc5-274874adf4d3 - summarizeBy: none - sourceColumn: sku.family - - annotation SummarizationSetBy = Automatic - - column 'properties.status' - dataType: string - lineageTag: 5acab20a-48e5-40a6-be42-4ce285d6050c - summarizeBy: none - sourceColumn: properties.status - - annotation SummarizationSetBy = Automatic - - column 'properties.requestedBackupStorageRedundancy' - dataType: string - lineageTag: 06b8e874-abdd-4169-ab5d-9bb0d77133e9 - summarizeBy: none - sourceColumn: properties.requestedBackupStorageRedundancy - - annotation SummarizationSetBy = Automatic - - column 'properties.currentBackupStorageRedundancy' - dataType: string - lineageTag: 9b75a75f-130c-4740-b1c6-5f8b5b2349a0 - summarizeBy: none - sourceColumn: properties.currentBackupStorageRedundancy - - annotation SummarizationSetBy = Automatic - - column 'properties.requestedServiceObjectiveName' - dataType: string - lineageTag: 5e0bca97-e4e6-48dd-b0cf-0aec6b495e54 - summarizeBy: none - sourceColumn: properties.requestedServiceObjectiveName - - annotation SummarizationSetBy = Automatic - - column 'properties.currentServiceObjectiveName' - dataType: string - lineageTag: b9f2c839-cb78-4fbd-a865-0b9bdcea1d93 - summarizeBy: none - sourceColumn: properties.currentServiceObjectiveName - - annotation SummarizationSetBy = Automatic - - column 'properties.maintenanceConfigurationId' - dataType: string - lineageTag: a70c975b-7ee1-4f9d-86ea-0a608ee1ca06 - summarizeBy: none - sourceColumn: properties.maintenanceConfigurationId - - annotation SummarizationSetBy = Automatic - - column 'properties.defaultSecondaryLocation' - dataType: string - lineageTag: 0618b4ff-529a-47ab-b17d-d3cc1b44a365 - summarizeBy: none - sourceColumn: properties.defaultSecondaryLocation - - annotation SummarizationSetBy = Automatic - - column 'properties.isInfraEncryptionEnabled' - dataType: string - lineageTag: 71c1a23e-de24-406d-8f60-2d37a331d8e2 - summarizeBy: none - sourceColumn: properties.isInfraEncryptionEnabled - - annotation SummarizationSetBy = Automatic - - column 'properties.earliestRestoreDate' - dataType: string - lineageTag: 5d9c2600-6d0a-41e5-8674-964c34ee2211 - summarizeBy: none - sourceColumn: properties.earliestRestoreDate - - annotation SummarizationSetBy = Automatic - - column 'properties.zoneRedundant' - dataType: string - lineageTag: 99c1096c-4e12-4f02-b8eb-b56b958ba0c1 - summarizeBy: none - sourceColumn: properties.zoneRedundant - - annotation SummarizationSetBy = Automatic - - column 'properties.availabilityZone' - dataType: string - lineageTag: f94ad863-bf18-46a0-9c48-0f5ca34e3c8a - summarizeBy: none - sourceColumn: properties.availabilityZone - - annotation SummarizationSetBy = Automatic - - column 'properties.catalogCollation' - dataType: string - lineageTag: 2bd47a2e-a367-4120-a8d9-8538155790fb - summarizeBy: none - sourceColumn: properties.catalogCollation - - annotation SummarizationSetBy = Automatic - - column 'properties.creationDate' - dataType: dateTime - formatString: General Date - lineageTag: f5cf5ffd-b2b2-482a-8573-1af7a4cce5b2 - summarizeBy: none - sourceColumn: properties.creationDate - - annotation SummarizationSetBy = Automatic - - column 'properties.collation' - dataType: string - lineageTag: 70eab20f-6666-4657-aca7-eb17823fc698 - summarizeBy: none - sourceColumn: properties.collation - - annotation SummarizationSetBy = Automatic - - column 'properties.licenseType' - dataType: string - lineageTag: 319756bd-fd30-4055-b93c-bd3eef82607c - summarizeBy: none - sourceColumn: properties.licenseType - - annotation SummarizationSetBy = Automatic - - column 'properties.maxSizeBytes' - dataType: string - lineageTag: ecc2bd34-5a78-4734-a156-296b640b1901 - summarizeBy: none - sourceColumn: properties.maxSizeBytes - - annotation SummarizationSetBy = Automatic - - column 'properties.isLedgerOn' - dataType: string - lineageTag: ae359e3d-1a28-4232-b24c-14e2d3d0d7d1 - summarizeBy: none - sourceColumn: properties.isLedgerOn - - annotation SummarizationSetBy = Automatic - - column 'properties.databaseId' - dataType: string - lineageTag: 300c3dce-a252-4c19-9eb8-f566861f76b0 - summarizeBy: none - sourceColumn: properties.databaseId - - annotation SummarizationSetBy = Automatic - - column 'properties.currentSku' - dataType: string - lineageTag: 13aba0ef-924c-4e25-81b2-5cca3fff3da1 - summarizeBy: none - sourceColumn: properties.currentSku - - annotation SummarizationSetBy = Automatic - - column 'properties.readScale' - dataType: string - lineageTag: 1459556c-62f2-40ff-9518-f258f7a053a8 - summarizeBy: none - sourceColumn: properties.readScale - - annotation SummarizationSetBy = Automatic - - column 'properties.maxLogSizeBytes' - dataType: string - lineageTag: 466ba7c2-ad63-45a4-bde1-8f17ea763bc2 - summarizeBy: none - sourceColumn: properties.maxLogSizeBytes - - annotation SummarizationSetBy = Automatic - - column location - dataType: string - lineageTag: 36ba9f05-8be1-420f-9b8e-66588e69fb4c - summarizeBy: none - sourceColumn: location - - annotation SummarizationSetBy = Automatic - - column resourceGroup - dataType: string - lineageTag: 2c7600e3-4a24-4d08-8829-2e3161a35ce8 - summarizeBy: none - sourceColumn: resourceGroup - - annotation SummarizationSetBy = Automatic - - partition SqlDatabases = m - mode: import - queryGroup: 'Resource Graph' - source = - let - query = " - resources - | where type == 'microsoft.sql/servers/databases' - | extend - ['sku.name'] = sku.name, - ['sku.tier'] = sku.tier, - ['sku.capacity'] = sku.capacity, - ['sku.family'] = sku.family, - ['properties.status'] = properties.status, - ['properties.requestedBackupStorageRedundancy'] = properties.requestedBackupStorageRedundancy, - ['properties.currentBackupStorageRedundancy'] = properties.currentBackupStorageRedundancy, - ['properties.requestedServiceObjectiveName'] = properties.requestedServiceObjectiveName, - ['properties.currentServiceObjectiveName'] = properties.currentServiceObjectiveName, - ['properties.maintenanceConfigurationId'] = properties.maintenanceConfigurationId, - ['properties.defaultSecondaryLocation'] = properties.defaultSecondaryLocation, - ['properties.isInfraEncryptionEnabled'] = properties.isInfraEncryptionEnabled, - ['properties.earliestRestoreDate'] = properties.earliestRestoreDate, - ['properties.zoneRedundant'] = properties.zoneRedundant, - ['properties.availabilityZone'] = properties.availabilityZone, - ['properties.catalogCollation'] = properties.catalogCollation, - ['properties.creationDate'] = properties.creationDate, - ['properties.collation'] = properties.collation, - ['properties.licenseType'] = properties.licenseType, - ['properties.maxSizeBytes'] = properties.maxSizeBytes, - ['properties.isLedgerOn'] = properties.isLedgerOn, - ['properties.databaseId'] = properties.databaseId, - ['properties.currentSku'] = properties.currentSku, - ['properties.readScale'] = properties.readScale, - ['properties.maxLogSizeBytes'] = properties.maxLogSizeBytes - " & ftk_DemoFilter(), - Source = AzureResourceGraph.Query(query, "Tenant", null, null, [resultTruncated = false]), - NullHandling = - if Table.HasColumns(Source, "Results") and Table.RowCount(Source) = 1 then - #table( - { "id", "name", "sku.name", "sku.tier", "sku.capacity", "sku.family", "location", "resourceGroup", "properties.status", "properties.requestedBackupStorageRedundancy", "properties.currentBackupStorageRedundancy", "properties.requestedServiceObjectiveName", "properties.currentServiceObjectiveName", "properties.maintenanceConfigurationId", "properties.defaultSecondaryLocation", "properties.isInfraEncryptionEnabled", "properties.earliestRestoreDate", "properties.zoneRedundant", "properties.availabilityZone", "properties.catalogCollation", "properties.creationDate", "properties.collation", "properties.licenseType", "properties.maxSizeBytes", "properties.isLedgerOn", "properties.databaseId", "properties.currentSku", "properties.readScale", "properties.maxLogSizeBytes" }, - {} - ) - else Source, - Types = Table.TransformColumnTypes(NullHandling, {{"properties.creationDate", type datetimezone}}) - in - Types - - annotation PBI_NavigationStepName = Navigation - - annotation PBI_ResultType = Table - diff --git a/src/power-bi/storage/Shared.Dataset/definition/tables/SqlDatabases.tmdl b/src/power-bi/storage/Shared.Dataset/definition/tables/SqlDatabases.tmdl new file mode 120000 index 000000000..076e27526 --- /dev/null +++ b/src/power-bi/storage/Shared.Dataset/definition/tables/SqlDatabases.tmdl @@ -0,0 +1 @@ +../../../../kql/Shared.Dataset/definition/tables/SqlDatabases.tmdl \ No newline at end of file diff --git a/src/power-bi/storage/Shared.Dataset/definition/tables/Subscriptions.tmdl b/src/power-bi/storage/Shared.Dataset/definition/tables/Subscriptions.tmdl deleted file mode 100644 index 28d8ec2da..000000000 --- a/src/power-bi/storage/Shared.Dataset/definition/tables/Subscriptions.tmdl +++ /dev/null @@ -1,175 +0,0 @@ -table Subscriptions - lineageTag: 07b667e4-2b48-4235-8cfb-5d59858a92fd - - column id - dataType: string - lineageTag: 793921fd-f3f6-4f61-b14e-8fa9430505b4 - summarizeBy: none - sourceColumn: id - - annotation SummarizationSetBy = Automatic - - column name - dataType: string - lineageTag: 8505a157-2e52-44c3-aae3-7a17aa29e660 - summarizeBy: none - sourceColumn: name - - annotation SummarizationSetBy = Automatic - - column type - dataType: string - lineageTag: f4dd6a96-342a-43f3-88a3-e1787d6d67b8 - summarizeBy: none - sourceColumn: type - - annotation SummarizationSetBy = Automatic - - column tenantId - dataType: string - lineageTag: 3194af1d-8e00-49df-86bb-8b491c39ae3d - summarizeBy: none - sourceColumn: tenantId - - annotation SummarizationSetBy = Automatic - - column kind - dataType: string - lineageTag: 540d1adf-2e23-4e17-afca-65de9fe9681b - summarizeBy: none - sourceColumn: kind - - annotation SummarizationSetBy = Automatic - - column location - dataType: string - lineageTag: 4ba56665-8cb0-448d-a51a-1d5847d1d651 - summarizeBy: none - sourceColumn: location - - annotation SummarizationSetBy = Automatic - - column resourceGroup - dataType: string - lineageTag: a1a2d9d2-d9f1-4109-b4c7-2eb2697004e9 - summarizeBy: none - sourceColumn: resourceGroup - - annotation SummarizationSetBy = Automatic - - column subscriptionId - dataType: string - lineageTag: 3ed589d4-d97f-460c-9f6f-81b131c8b8b2 - summarizeBy: none - sourceColumn: subscriptionId - - annotation SummarizationSetBy = Automatic - - column managedBy - dataType: string - lineageTag: 5be96267-523e-4c25-823c-ed29e37bd321 - summarizeBy: none - sourceColumn: managedBy - - annotation SummarizationSetBy = Automatic - - column sku - dataType: string - lineageTag: 21317308-a1e5-495b-9e1c-d0e60fa9e45e - summarizeBy: none - sourceColumn: sku - - annotation SummarizationSetBy = Automatic - - column plan - dataType: string - lineageTag: 71a123ff-da4e-40a8-9e8a-51cf3e0cd91b - summarizeBy: none - sourceColumn: plan - - annotation SummarizationSetBy = Automatic - - column tags - dataType: string - lineageTag: ff48b324-4a1c-488d-97d3-f9f59e0b7f3c - summarizeBy: none - sourceColumn: tags - - annotation SummarizationSetBy = Automatic - - column identity - dataType: string - lineageTag: c13df37c-910c-432c-a474-b7d68dbc1ddb - summarizeBy: none - sourceColumn: identity - - annotation SummarizationSetBy = Automatic - - column zones - dataType: string - lineageTag: 39936a9e-4e8c-4e26-9688-6a23cbe4804d - summarizeBy: none - sourceColumn: zones - - annotation SummarizationSetBy = Automatic - - column extendedLocation - dataType: string - lineageTag: a6bc54f9-1649-4b14-b916-70b557245ac4 - summarizeBy: none - sourceColumn: extendedLocation - - annotation SummarizationSetBy = Automatic - - column properties - dataType: string - lineageTag: 6a2cd7e5-ed25-4b1c-b06f-29a947c9b8d6 - summarizeBy: none - sourceColumn: properties - - annotation SummarizationSetBy = Automatic - - column 'properties.managementGroupAncestorsChain' - dataType: string - lineageTag: fbb4c9cd-dcfc-4b61-8bc7-42b8dfd82e50 - summarizeBy: none - sourceColumn: properties.managementGroupAncestorsChain - - annotation SummarizationSetBy = Automatic - - column 'properties.state' - dataType: string - lineageTag: c37d69f0-5039-4418-94b9-44fcd6690201 - summarizeBy: none - sourceColumn: properties.state - - annotation SummarizationSetBy = Automatic - - partition Subscriptions = m - mode: import - queryGroup: 'Resource Graph' - source = ``` - let - query = " - resourcecontainers - | where type == 'microsoft.resources/subscriptions' - | extend - ['properties.managementGroupAncestorsChain'] = properties.managementGroupAncestorsChain, - ['properties.state'] = properties.state - " & ftk_DemoFilter(), - Source = AzureResourceGraph.Query(query, "Tenant", null, null, [resultTruncated = false]), - NullHandling = - if Table.HasColumns(Source, "Results") and Table.RowCount(Source) = 1 then - #table( - { "id", "name", "type", "subscriptionId", "tenantId", "properties.managementGroupAncestorsChain", "properties.state" }, - {} - ) - else Source - in - NullHandling - ``` - - annotation PBI_NavigationStepName = Navigation - - annotation PBI_ResultType = Table - diff --git a/src/power-bi/storage/Shared.Dataset/definition/tables/Subscriptions.tmdl b/src/power-bi/storage/Shared.Dataset/definition/tables/Subscriptions.tmdl new file mode 120000 index 000000000..71dd57f47 --- /dev/null +++ b/src/power-bi/storage/Shared.Dataset/definition/tables/Subscriptions.tmdl @@ -0,0 +1 @@ +../../../../kql/Shared.Dataset/definition/tables/Subscriptions.tmdl \ No newline at end of file diff --git a/src/power-bi/storage/Shared.Dataset/definition/tables/VirtualMachines.tmdl b/src/power-bi/storage/Shared.Dataset/definition/tables/VirtualMachines.tmdl deleted file mode 100644 index 47851cbbc..000000000 --- a/src/power-bi/storage/Shared.Dataset/definition/tables/VirtualMachines.tmdl +++ /dev/null @@ -1,536 +0,0 @@ -table VirtualMachines - lineageTag: bc3b3e64-3016-4758-897f-eeae6043bd77 - - column id - dataType: string - lineageTag: aabba0f4-f3dd-44b1-8976-664cfcb25bbd - summarizeBy: none - sourceColumn: id - - annotation SummarizationSetBy = Automatic - - column name - dataType: string - lineageTag: 8dd0096e-87b5-452b-bf31-cdd348a545ec - summarizeBy: none - sourceColumn: name - - annotation SummarizationSetBy = Automatic - - column provisioningState - dataType: string - lineageTag: f8c7e75f-672b-438c-bf36-d638b2f32fa7 - summarizeBy: none - sourceColumn: provisioningState - - annotation SummarizationSetBy = Automatic - - column timeCreated - dataType: string - lineageTag: 17f797bb-49c7-4cb4-9be4-2e043232a35d - summarizeBy: none - sourceColumn: timeCreated - - annotation SummarizationSetBy = Automatic - - column 'networkInterfaces.properties.deleteOption' - dataType: string - lineageTag: 554004cc-811f-4dde-862a-dac3930dfe6d - summarizeBy: none - sourceColumn: networkInterfaces.properties.deleteOption - - annotation SummarizationSetBy = Automatic - - column 'networkInterfaces.id' - dataType: string - lineageTag: 939a3bed-0418-4daa-a584-2e8e22707d36 - summarizeBy: none - sourceColumn: networkInterfaces.id - - annotation SummarizationSetBy = Automatic - - column 'osProfile.computerName' - dataType: string - lineageTag: 991a5af1-9bcc-45b1-a61f-c96679b5299c - summarizeBy: none - sourceColumn: osProfile.computerName - - annotation SummarizationSetBy = Automatic - - column 'osProfile.requireGuestProvisionSignal' - dataType: string - lineageTag: 2c1729b5-b12d-44d5-9a8a-770ecef7e443 - summarizeBy: none - sourceColumn: osProfile.requireGuestProvisionSignal - - annotation SummarizationSetBy = Automatic - - column 'osProfile.allowExtensionOperations' - dataType: string - lineageTag: 909cdeef-5a65-4fec-ac70-b611dd8694a3 - summarizeBy: none - sourceColumn: osProfile.allowExtensionOperations - - annotation SummarizationSetBy = Automatic - - column 'osProfile.adminUsername' - dataType: string - lineageTag: ca20db16-1cec-4d87-8116-fd33c1c52ab6 - summarizeBy: none - sourceColumn: osProfile.adminUsername - - annotation SummarizationSetBy = Automatic - - column 'osProfile.secrets' - dataType: string - lineageTag: f61d4998-0550-4787-96dc-b862adec39ad - summarizeBy: none - sourceColumn: osProfile.secrets - - annotation SummarizationSetBy = Automatic - - column 'osProfile.linuxConfiguration' - dataType: string - lineageTag: 9f5d66ab-2c26-4788-acb0-4fb1124af210 - summarizeBy: none - sourceColumn: osProfile.linuxConfiguration - - annotation SummarizationSetBy = Automatic - - column 'osProfile.windowsConfiguration' - dataType: string - lineageTag: 9939f09a-936e-455b-9ffd-81fef08964b0 - summarizeBy: none - sourceColumn: osProfile.windowsConfiguration - - annotation SummarizationSetBy = Automatic - - column 'storageProfile.imageReference.publisher' - dataType: string - lineageTag: 81517633-977d-44f0-988b-b0d929045952 - summarizeBy: none - sourceColumn: storageProfile.imageReference.publisher - - annotation SummarizationSetBy = Automatic - - column 'storageProfile.imageReference.sku' - dataType: string - lineageTag: aeb7e0ca-2b7b-4b87-acf7-c62c9393e177 - summarizeBy: none - sourceColumn: storageProfile.imageReference.sku - - annotation SummarizationSetBy = Automatic - - column 'storageProfile.imageReference.version' - dataType: string - lineageTag: 3a9f2c79-ae20-49af-932b-d8d4245c5d32 - summarizeBy: none - sourceColumn: storageProfile.imageReference.version - - annotation SummarizationSetBy = Automatic - - column 'storageProfile.imageReference.exactVersion' - dataType: string - lineageTag: 9b0a4e2f-a55e-4e7b-8143-6a7019f53b6a - summarizeBy: none - sourceColumn: storageProfile.imageReference.exactVersion - - annotation SummarizationSetBy = Automatic - - column 'storageProfile.imageReference.offer' - dataType: string - lineageTag: 157f58e3-6ce8-4397-b0db-578cc680828f - summarizeBy: none - sourceColumn: storageProfile.imageReference.offer - - annotation SummarizationSetBy = Automatic - - column 'storageProfile.dataDisks.name' - dataType: string - lineageTag: 727d23eb-c156-4a16-a732-58e17c7f65ec - summarizeBy: none - sourceColumn: storageProfile.dataDisks.name - - annotation SummarizationSetBy = Automatic - - column 'storageProfile.dataDisks.createOption' - dataType: string - lineageTag: 56a3f6cc-9aae-4967-937e-2cf37b34a3ec - summarizeBy: none - sourceColumn: storageProfile.dataDisks.createOption - - annotation SummarizationSetBy = Automatic - - column 'storageProfile.dataDisks.deleteOption' - dataType: string - lineageTag: ee0d1c42-8700-4004-acbd-270256062de9 - summarizeBy: none - sourceColumn: storageProfile.dataDisks.deleteOption - - annotation SummarizationSetBy = Automatic - - column 'storageProfile.dataDisks.managedDisk.id' - dataType: string - lineageTag: d3b45be8-8d78-4075-8a06-313042ad6f88 - summarizeBy: none - sourceColumn: storageProfile.dataDisks.managedDisk.id - - annotation SummarizationSetBy = Automatic - - column 'storageProfile.dataDisks.caching' - dataType: string - lineageTag: c1d37b38-b93c-46bd-8408-6b61fb407dc7 - summarizeBy: none - sourceColumn: storageProfile.dataDisks.caching - - annotation SummarizationSetBy = Automatic - - column 'storageProfile.dataDisks.toBeDetached' - dataType: string - lineageTag: e933b3f8-fd92-4b5a-9813-18a4cd0218eb - summarizeBy: none - sourceColumn: storageProfile.dataDisks.toBeDetached - - annotation SummarizationSetBy = Automatic - - column 'storageProfile.dataDisks.writeAcceleratorEnabled' - dataType: string - lineageTag: c7979256-5152-4cee-9be5-11b2408253a6 - summarizeBy: none - sourceColumn: storageProfile.dataDisks.writeAcceleratorEnabled - - annotation SummarizationSetBy = Automatic - - column 'storageProfile.dataDisks.lun' - dataType: string - lineageTag: 23627fcb-60b2-45f6-a257-1207e544cc63 - summarizeBy: none - sourceColumn: storageProfile.dataDisks.lun - - annotation SummarizationSetBy = Automatic - - column 'storageProfile.osDisk.name' - dataType: string - lineageTag: bc9c01d8-8cf3-4bca-aba4-de325bf9fb35 - summarizeBy: none - sourceColumn: storageProfile.osDisk.name - - annotation SummarizationSetBy = Automatic - - column 'storageProfile.osDisk.createOption' - dataType: string - lineageTag: 19288f47-9a67-48ff-ae49-a60fc4d22e3d - summarizeBy: none - sourceColumn: storageProfile.osDisk.createOption - - annotation SummarizationSetBy = Automatic - - column 'storageProfile.osDisk.osType' - dataType: string - lineageTag: 52dbf86f-4936-4258-8d30-30fd7e2280ae - summarizeBy: none - sourceColumn: storageProfile.osDisk.osType - - annotation SummarizationSetBy = Automatic - - column 'storageProfile.osDisk.deleteOption' - dataType: string - lineageTag: 8033fb68-7806-4d13-ae45-6d84ef8f5c9a - summarizeBy: none - sourceColumn: storageProfile.osDisk.deleteOption - - annotation SummarizationSetBy = Automatic - - column 'storageProfile.osDisk.managedDisk.id' - dataType: string - lineageTag: eef9ea0b-b112-4577-a964-935f247ef493 - summarizeBy: none - sourceColumn: storageProfile.osDisk.managedDisk.id - - annotation SummarizationSetBy = Automatic - - column 'storageProfile.osDisk.caching' - dataType: string - lineageTag: 5301af8a-1f76-4c1d-9122-69dcf00b7594 - summarizeBy: none - sourceColumn: storageProfile.osDisk.caching - - annotation SummarizationSetBy = Automatic - - column 'hardwareProfile.vmSize' - dataType: string - lineageTag: 7c391f84-138d-42dc-b710-96526d722d74 - summarizeBy: none - sourceColumn: hardwareProfile.vmSize - - annotation SummarizationSetBy = Automatic - - column vmId - dataType: string - lineageTag: 0c594826-f13f-4054-adbe-1eb9c8e0aebb - summarizeBy: none - sourceColumn: vmId - - annotation SummarizationSetBy = Automatic - - column 'diagnosticsProfile.bootDiagnostics.enabled' - dataType: string - lineageTag: d5dcd997-9933-4afa-86c4-d2d4fe865970 - summarizeBy: none - sourceColumn: diagnosticsProfile.bootDiagnostics.enabled - - annotation SummarizationSetBy = Automatic - - column 'diagnosticsProfile.bootDiagnostics.storageUri' - dataType: string - lineageTag: 0d8d0d6a-763f-4cd9-bf2b-625d32f8dc4d - summarizeBy: none - sourceColumn: diagnosticsProfile.bootDiagnostics.storageUri - - annotation SummarizationSetBy = Automatic - - column 'powerState.displayStatus' - dataType: string - lineageTag: 1138b30d-fa61-49f8-badc-879c58ca77c2 - summarizeBy: none - sourceColumn: powerState.displayStatus - - annotation SummarizationSetBy = Automatic - - column licenseType - dataType: string - lineageTag: 15e7fcf4-e6b1-4187-b9f4-2a4841f82aff - summarizeBy: none - sourceColumn: licenseType - - annotation SummarizationSetBy = Automatic - - column networkProfile - dataType: string - lineageTag: 1d17fabc-ac29-4729-bec9-7dd7d2563157 - summarizeBy: none - sourceColumn: networkProfile - - annotation SummarizationSetBy = Automatic - - column osProfile - dataType: string - lineageTag: 9f3d6f62-d5b4-4ba6-861e-21b60f25b808 - summarizeBy: none - sourceColumn: osProfile - - annotation SummarizationSetBy = Automatic - - column storageProfile - dataType: string - lineageTag: abf3f952-863f-4d23-af62-a2ea31887c3a - summarizeBy: none - sourceColumn: storageProfile - - annotation SummarizationSetBy = Automatic - - column hardwareProfile - dataType: string - lineageTag: 18998ba6-333c-4462-bd93-d54814e2361d - summarizeBy: none - sourceColumn: hardwareProfile - - annotation SummarizationSetBy = Automatic - - column diagnosticsProfile - dataType: string - lineageTag: 002811fd-e4da-412c-aec8-789c872382f5 - summarizeBy: none - sourceColumn: diagnosticsProfile - - annotation SummarizationSetBy = Automatic - - column extended - dataType: string - lineageTag: 695947e2-c1e6-440a-9379-d4ace0486833 - summarizeBy: none - sourceColumn: extended - - annotation SummarizationSetBy = Automatic - - column networkInterfaces - dataType: string - lineageTag: 60df4e28-c5a2-4be4-a666-5f6399869a0d - summarizeBy: none - sourceColumn: networkInterfaces - - annotation SummarizationSetBy = Automatic - - column 'networkInterfaces.properties' - dataType: string - lineageTag: b85e2971-0782-48ce-8641-f8e720fef81a - summarizeBy: none - sourceColumn: networkInterfaces.properties - - annotation SummarizationSetBy = Automatic - - column 'storageProfile.imageReference' - dataType: string - lineageTag: fce31b16-8d80-4267-86f7-458827788e2d - summarizeBy: none - sourceColumn: storageProfile.imageReference - - annotation SummarizationSetBy = Automatic - - column 'storageProfile.dataDisks' - dataType: string - lineageTag: bb2a82e8-695a-47a9-bcbb-611e134356ed - summarizeBy: none - sourceColumn: storageProfile.dataDisks - - annotation SummarizationSetBy = Automatic - - column 'storageProfile.osDisk' - dataType: string - lineageTag: 8fdcc755-3ffb-48b1-bf3f-e46db8f67774 - summarizeBy: none - sourceColumn: storageProfile.osDisk - - annotation SummarizationSetBy = Automatic - - column 'storageProfile.dataDisks.managedDisk' - dataType: string - lineageTag: 56634ea0-bbc4-4587-854c-ba252faa1ae8 - summarizeBy: none - sourceColumn: storageProfile.dataDisks.managedDisk - - annotation SummarizationSetBy = Automatic - - column 'storageProfile.osDisk.managedDisk' - dataType: string - lineageTag: a3f5aff1-c5e8-4957-bb33-84f23977d4a2 - summarizeBy: none - sourceColumn: storageProfile.osDisk.managedDisk - - annotation SummarizationSetBy = Automatic - - column 'diagnosticsProfile.bootDiagnostics' - dataType: string - lineageTag: 3ef88619-6923-44d5-a101-36274a025e49 - summarizeBy: none - sourceColumn: diagnosticsProfile.bootDiagnostics - - annotation SummarizationSetBy = Automatic - - column instanceView - dataType: string - lineageTag: af5bca80-4901-41c9-ab40-3fc346f0912f - summarizeBy: none - sourceColumn: instanceView - - annotation SummarizationSetBy = Automatic - - column powerState - dataType: string - lineageTag: 2debf081-3956-4289-a117-8b7af6888ac1 - summarizeBy: none - sourceColumn: powerState - - annotation SummarizationSetBy = Automatic - - column location - dataType: string - lineageTag: 3d3b7faf-7dbb-4cb2-b29a-4bb60cfb8c9c - summarizeBy: none - sourceColumn: location - - annotation SummarizationSetBy = Automatic - - column resourceGroup - dataType: string - lineageTag: 71c32f19-f5ec-4c9c-a2e3-3f7c20d7f9e8 - summarizeBy: none - sourceColumn: resourceGroup - - annotation SummarizationSetBy = Automatic - - partition VirtualMachines = m - mode: import - queryGroup: 'Resource Graph' - source = - let - query = " - Resources - | where type =~ 'Microsoft.Compute/virtualMachines' - | extend - provisioningState = properties.provisioningState, - timeCreated = properties.timeCreated, - networkProfile = properties.networkProfile, - osProfile = properties.osProfile, - storageProfile = properties.storageProfile, - hardwareProfile = properties.hardwareProfile, - vmId = properties.vmId, - diagnosticsProfile = properties.diagnosticsProfile, - extended = properties.extended, - licenseType = properties.licenseType - | extend - ['osProfile.computerName'] = osProfile.computerName, - ['osProfile.requireGuestProvisionSignal'] = osProfile.requireGuestProvisionSignal, - ['osProfile.allowExtensionOperations'] = osProfile.allowExtensionOperations, - ['osProfile.adminUsername'] = osProfile.adminUsername, - ['osProfile.secrets'] = osProfile.secrets, - ['osProfile.linuxConfiguration'] = osProfile.linuxConfiguration, - ['osProfile.windowsConfiguration'] = osProfile.windowsConfiguration, - networkInterfaces = networkProfile.networkInterfaces - | mv-expand ['networkInterfaces'] - | extend - ['networkInterfaces.properties'] = networkInterfaces.properties, - ['networkInterfaces.id'] = networkInterfaces.id, - ['networkInterfaces.properties.deleteOption'] = networkInterfaces.properties.deleteOption, - ['storageProfile.imageReference'] = storageProfile.imageReference, - ['storageProfile.dataDisks'] = storageProfile.dataDisks, - ['storageProfile.osDisk'] = storageProfile.osDisk, - ['storageProfile.imageReference.publisher'] = storageProfile.imageReference.publisher, - ['storageProfile.imageReference.sku'] = storageProfile.imageReference.sku, - ['storageProfile.imageReference.version'] = storageProfile.imageReference.version, - ['storageProfile.imageReference.exactVersion'] = storageProfile.imageReference.exactVersion, - ['storageProfile.imageReference.offer'] = storageProfile.imageReference.offer - | mv-expand ['storageProfile.dataDisks'] - | extend - ['storageProfile.dataDisks.name'] = storageProfile.dataDisks.name, - ['storageProfile.dataDisks.createOption'] = storageProfile.dataDisks.createOption, - ['storageProfile.dataDisks.deleteOption'] = storageProfile.dataDisks.deleteOption, - ['storageProfile.dataDisks.managedDisk'] = storageProfile.dataDisks.managedDisk, - ['storageProfile.dataDisks.caching'] = storageProfile.dataDisks.caching, - ['storageProfile.dataDisks.toBeDetached'] = storageProfile.dataDisks.toBeDetached, - ['storageProfile.dataDisks.writeAcceleratorEnabled'] = storageProfile.dataDisks.writeAcceleratorEnabled, - ['storageProfile.dataDisks.lun'] = storageProfile.dataDisks.lun, - ['storageProfile.dataDisks.managedDisk.id'] = storageProfile.dataDisks.managedDisk.id, - ['storageProfile.osDisk.name'] = storageProfile.osDisk.name, - ['storageProfile.osDisk.createOption'] = storageProfile.osDisk.createOption, - ['storageProfile.osDisk.osType'] = storageProfile.osDisk.osType, - ['storageProfile.osDisk.deleteOption'] = storageProfile.osDisk.deleteOption, - ['storageProfile.osDisk.managedDisk'] = storageProfile.osDisk.managedDisk, - ['storageProfile.osDisk.caching'] = storageProfile.osDisk.caching, - ['storageProfile.osDisk.managedDisk.id'] = storageProfile.osDisk.managedDisk.id, - ['hardwareProfile.vmSize'] = hardwareProfile.vmSize, - ['diagnosticsProfile.bootDiagnostics'] = diagnosticsProfile.bootDiagnostics, - ['diagnosticsProfile.bootDiagnostics.enabled'] = diagnosticsProfile.bootDiagnostics.enabled, - ['diagnosticsProfile.bootDiagnostics.storageUri'] = diagnosticsProfile.bootDiagnostics.storageUri - | extend - instanceView = extended.instanceView, - powerState = extended.instanceView.powerState - | extend - ['powerState.displayStatus'] = powerState.displayStatus - | mv-expand ['zones'] - " & ftk_DemoFilter(), - Source = AzureResourceGraph.Query(query, "Tenant", null, null, [resultTruncated = false]), - NullHandling = - if Table.HasColumns(Source, "Results") and Table.RowCount(Source) = 1 then - #table( - { "id", "name", "location", "resourceGroup", "provisioningState", "timeCreated", "networkProfile", "osProfile", "storageProfile", "hardwareProfile", "vmId", "diagnosticsProfile", "extended", "licenseType", "osProfile.computerName", "osProfile.requireGuestProvisionSignal", "osProfile.allowExtensionOperations", "osProfile.adminUsername", "osProfile.secrets", "osProfile.linuxConfiguration", "osProfile.windowsConfiguration", "networkInterfaces", "networkInterfaces.properties", "networkInterfaces.id", "networkInterfaces.properties.deleteOption", "storageProfile.imageReference", "storageProfile.dataDisks", "storageProfile.osDisk", "storageProfile.imageReference.publisher", "storageProfile.imageReference.sku", "storageProfile.imageReference.version", "storageProfile.imageReference.exactVersion", "storageProfile.imageReference.offer", "storageProfile.dataDisks.name", "storageProfile.dataDisks.createOption", "storageProfile.dataDisks.deleteOption", "storageProfile.dataDisks.managedDisk", "storageProfile.dataDisks.caching", "storageProfile.dataDisks.toBeDetached", "storageProfile.dataDisks.writeAcceleratorEnabled", "storageProfile.dataDisks.lun", "storageProfile.dataDisks.managedDisk.id", "storageProfile.osDisk.name", "storageProfile.osDisk.createOption", "storageProfile.osDisk.osType", "storageProfile.osDisk.deleteOption", "storageProfile.osDisk.managedDisk", "storageProfile.osDisk.caching", "storageProfile.osDisk.managedDisk.id", "hardwareProfile.vmSize", "diagnosticsProfile.bootDiagnostics", "diagnosticsProfile.bootDiagnostics.enabled", "diagnosticsProfile.bootDiagnostics.storageUri", "instanceView", "powerState", "powerState.displayStatus" }, - {} - ) - else Source - in - NullHandling - - annotation PBI_NavigationStepName = Navigation - - annotation PBI_ResultType = Table - diff --git a/src/power-bi/storage/Shared.Dataset/definition/tables/VirtualMachines.tmdl b/src/power-bi/storage/Shared.Dataset/definition/tables/VirtualMachines.tmdl new file mode 120000 index 000000000..2590be6d5 --- /dev/null +++ b/src/power-bi/storage/Shared.Dataset/definition/tables/VirtualMachines.tmdl @@ -0,0 +1 @@ +../../../../kql/Shared.Dataset/definition/tables/VirtualMachines.tmdl \ No newline at end of file