Forum Discussion
An error occurred while processing the semantic model
- 10 months ago
Hi Anonymousap ,
Thanks for reaching out to Microsoft Fabric Community and thanks for sharing the additional details.
Since the issue is intermittent, it is likely related to how the Power BI mashup engine processes data. Even if the queries run fine in SQL, temporary tables are created in the background during refresh. If these temp tables encounter duplicate values in columns used as keys, or if there are concurrent operations, it can occasionally trigger the “An error occurred while processing the semantic model” message.
Here are some steps given which resolved a similar issue: Solved: Re: Refresh failure - Microsoft Fabric Community
As mentioned by tayloramy , sharing the script that creates any temp tables and the structure of the source tables would also help in understanding why duplicates may be generated.
The gateway timeout error seen for PBI_ProdMetalTable is generally unrelated to duplicates. It may happen if the gateway server experiences resource constraints, network latency, or long-running queries. Increasing the timeout settings for the data source can help address this issue as mentioned here: Solved: Re: Dataset refresh error - timeout - Microsoft Fabric Community
Also, as already mentioned by tayloramy checking the gateway server for available resources, running the network port test, and monitoring refresh performance during scheduled windows can help identify the cause. Capturing advanced gateway logs during a failing refresh is also recommended.
Thanks to ibarrau and tayloramy again for addressing this earlier and valuable guidance.
Please reach out for further assistance.
Thank you.
Hi The error is specifying that you have a duplicated value for a column of a table that is used for a relationship a 1 cardinality. It can't contain duplicated so it fails. This message can show what it's talking about:
Violation of PRIMARY KEY constraint 'PK__#tmpJewe__44BDA513E14627E4'. Cannot insert duplicate key in object 'dbo.#tmpJewel'. The duplicate key value is (3144096)."}}, Table: Pbi_BagStatusWIP.
Check for the value 3144096 at the key column used for relationship of the table Pbi_BagStatusWIP. Fix the model issue to check if that value is a wrong data entry or if you should be removing duplicates.
I hope that helps,
ibarrau Thank you for the relpy,
but Table: Pbi_BagStatusWIP does not contains any primary key and i am facing this erros for other table or view as well, like yesterday same error occured but due to other table
| Data source error: | {"error":{"code":"DM_GWPipeline_Gateway_TimeoutError","pbi.error":{"code":"DM_GWPipeline_Gateway_TimeoutError","parameters":{},"details":[],"exceptionCulprit":1}}} Table: PBI_ProdMetalTable. | |||||||
| Cluster URI: | WABI-INDIA-CENTRAL-A-PRIMARY-redirect.analysis.windows.net | |||||||
| Activity ID: | 1038ef22-80bc-486a-a6b5-1c6af4d215ac | |||||||
| Request ID: | 9de8040d-626e-4d69-84e0-e3a79e2686ed | |||||||
| Time: | 2025-10-03 09:38:35Z | |||||||
| Details | # Type Start End Duration Status Details
|