microsoft / secmgmt-insights-connector

Power BI connector that provides insight into the current state of how Microsoft 365 is configured and whether best practices have been implemented
MIT License
13 stars 3 forks source link

OneDrive usage detail #69

Closed ghost closed 4 years ago

ghost commented 4 years ago

Steps to reproduce

Run the following query

SecMgmtInsights.OneDriveUsageAccountDetail(GetTenantList())

Expected behavior

The resulting table should contain data

Actual behavior

The resulting table contains a Value column with either null or a record

Environment

Windows 10 Power BI Desktop SecMgmtInsights version 1.3

ghost commented 4 years ago

The following section from the Request.GraphFeed function is the cause for this issue

// BUG - The following line is the reason for https://github.com/microsoft/secmgmt-insights-connector/issues/69
entries = if(expandedList{0}[Value] = null) then 
        expandedList 
    else 
        let
            listOfColumns = Record.FieldNames(expandedList{0}[Value]), 
            expandedTable = Table.ExpandRecordColumn(expandedList, "Value", listOfColumns, listOfColumns)
        in 
            expandedTable,