1. 某個實體處理失敗,錯誤代碼爲 0x80040237 ,錯誤消息爲 Cannot insert duplicate key.html
最好先檢查下錯誤消息中涉及到 CustomControlDefaultConfig 視圖的,目前比較推薦的作法是解壓解決方案,將customizaztion.xml中的該實體的CustomControlDefaultConfigs 元素註釋掉,不過可能每次都須要這麼作。我下面這個方法比較暴力,使用以下SQL刪除數據後再導入就能夠了,請注意,直接操做數據庫是不受支持的開發方法,通常不要在生產環境操做。數據庫
Delete from CustomControlDefaultConfigBase where PrimaryEntityTypeCode = (select ObjectTypeCode from entity where logicalname ='ly_test')
2. 依賴項計算失敗,錯誤代碼爲 0x80040216 ,錯誤消息相似 不能在具備惟一索引「ndx_UniqueDependencyNodes」的對象「dbo.DependencyBase」中插入重複鍵的行。重複鍵值爲 (af1234bf-5632-4244-82f7-9be79c1ba983, 61a737e1-47cd-4321-b455-715b753bc4be)。 語句已終止。ui
可能能夠使用以下SQL刪除數據後導入,請注意,直接操做數據庫是不受支持的開發方法,通常不要在生產環境操做。spa
Delete from DependencyBase where RequiredComponentNodeId='af1234bf-5632-4244-82f7-9be79c1ba983' and DependentComponentNodeId='61a737e1-47cd-4321-b455-715b753bc4be'
本文來自:https://www.cnblogs.com/luoyong0201/p/Dynamics_365_Solve_Import_Solution_Error.htmlcode