Forum Discussion

mr_wizard's avatar
mr_wizard
Resolver I
1 year ago
Solved

how to resolve query timeout problem

I have a semantic model that is experiencing a query timeout.  I need help to make it not experience the timeout.   The model is in Import mode.  When it runs a refresh in the service, it throws th...
  • rohit1991's avatar
    1 year ago

    Hi mr_wizard ,

    You're encountering a query timeout issue during the refresh of an import-mode semantic model in Power BI, despite having increased the query timeout setting in the service to two hours. Given that the error consistently occurs around the 40-minute mark, it's unlikely the issue stems from the Power BI service's query timeout configuration. Instead, the problem may lie with the data source or the underlying infrastructure—particularly the Azure SQL Managed Instance you're connecting to.

     

    Even if Power BI allows longer execution times, SQL Server itself may have internal limits or resource governance policies (such as workload group timeouts, resource pool limits, or session timeouts) that terminate long-running queries. Additionally, gateway timeout settings or network-level interruptions could also be involved. Since your model uses a large fact table with 30M rows and cannot leverage incremental refresh due to data volatility, you might explore breaking the refresh into smaller partitions using XMLA endpoints or optimizing the query itself through indexing, query tuning, or reducing unnecessary columns and rows. It’s also worth reviewing SQL Server execution plans for bottlenecks and working with your DBA to ensure no throttling or session limits are being imposed. If feasible, consider whether hybrid strategies, such as staging data into intermediary tables or snapshots, can help mitigate the performance overhead during refresh.