SMSAgentSoftware / MEM

Microsoft Endpoint Manager related resources
25 stars 15 forks source link

Issue with PowerBI Template - 17 queries blocked by the following error: #12

Closed LukassUK closed 2 months ago

LukassUK commented 2 months ago

Hi,

After successfully implementing the client script and runbooks, we are facing a problem with the Power BI template. When the template is opened, we enter the workspace ID and retention period and the report opens and immediately starts a refresh. We then get a error saying: 17 queries are blocked with the following error:

Web.Contents failed to get contents from 'https://api.loganalytics.io/v1/workspaces/%WORKSPACE_ID%/query?query=SU_WindowsSetup_CL%0A%7C%20where%20column_ifexists%28%22SetupHostResult_d%22%2C%22nada%22%29%20%3D%3D%200%0A%7C%20where%20isnotnull%28column_ifexists%28%22DownlevelBuildNumber_d%22%2C%22nada%22%29%29%0A%7C%20summarize%20arg_max%28TimeGenerated%2C%2A%29%20by%20IntuneDeviceID_g%0A%7C%20join%20kind%3Dleftouter%20%28SU_ClientComplianceStatus_CL%0A%20%20%20%20%7C%20summarize%20arg_max%28InventoryDate_t%2C%2A%29%20by%20IntuneDeviceID_g%0A%20%20%20%20%7C%20project%20IntuneDeviceID_g%2CCurrentUser_s%2CDisplayVersion_s%2CEditionID_s%2CFriendlyOSName_s%2CFullBuildNmber_s%2CLastSyncTime_t%2CProductName_s%2CWindows_Release_s%0A%29%20on%20IntuneDeviceID_g%0A%7C%20join%20kind%3Dleftouter%20%20%28SU_OSUpdateHistory_CL%0A%20%20%20%20%7C%20distinct%20OSBaseBuild_d%2COSVersion_s%0A%20%20%20%20%7C%20project%20OSBaseBuild_d%2COSVersion_s%0A%29%20on%20%24left.DownlevelBuildNumber_d%20%3D%3D%20%24right.OSBaseBuild_d%0' (400): Bad Request

PowerBIError

Any help or advice would be much appreciated please.

Many thanks

SMSAgentSoftware commented 2 months ago

Hi, this issue was mentioned in https://github.com/SMSAgentSoftware/MEM/issues/9 which you have also commented on. If you are able to add the missing columns from the schema to the "SU_WindowsSetup_CL" table in the Log Analytics workspace, this should fix the issue. If you are unable to add the missing columns, an alternative would be to simply right-click the "WindowsUpgradeSuccesses" table in the Power BI report and choose "Delete from model". This will remove that query from the report - you'd want to remove the corresponding report page as well as it won't show any data. If you do get the required columns added to the LA table at some point, you can simply download a new copy of the report to add that query back in.

LukassUK commented 2 months ago

Thanks very much indeed - working fine now.