简体   繁体   English

Dynamics CRM:无法更改记录所有者

[英]Dynamics CRM: Unable to change record owner

Re: Dynamics CRM 2015 On-Prem 回复:Dynamics CRM 2015内部部署

We have a strange issue that started happening today. 我们今天遇到了一个奇怪的问题。 In short, we cant change any record owners. 简而言之,我们不能更改任何唱片所有者。 I even tried on a newly created entity. 我什至尝试了一个新创建的实体。 After changing the owner, whether its manually selecting the owner or using the assign feature, the form refreshes upon saving and it reverts back to the previous owner. 更改所有者后,无论是手动选择所有者还是使用分配功能,表单在保存时都会刷新,并恢复为先前的所有者。 No, we don't have any new OnSave / OnLoad Java scripts or any new workflow/plugins. 不,我们没有任何新的OnSave / OnLoad Java脚本或任何新的工作流程/插件。 The only change to the environment was that we rolled back update 0.3, and we since reinstalled it. 对环境的唯一更改是我们回滚了更新0.3,并且此后重新安装了该更新。

Update 更新资料

I think you're right Jacob. 我认为你是对的雅各。 I tried upgrading the org to 7.03, but its failing. 我尝试将组织升级到7.03,但是失败了。 It's seemingly looking for something that doesn't exists "subscriptionstatisticsoutlookbase". 它似乎正在寻找不存在的“ subscriptionstatisticsoutlookbase”。 Is it supposed to be a table? 应该是桌子吗? Can I manually create this? 我可以手动创建吗?

 System.Data.SqlClient.SqlException: Invalid object name 'SubscriptionStatisticsOutlookBase'.

Update 2 更新2

I'm updating and tagging the SQL folks. 我正在更新和标记SQL人员。 I'm working with PSS but so far nothing. 我正在使用PSS,但到目前为止没有任何帮助。 Im getting the same error when trying to upgrade to 2016, so perhaps this is a clue. 我在尝试升级到2016年时遇到了同样的错误,所以也许这是一个线索。 I copied the SQL statement from the logs to a SQL query, and of course IntelliSense is throwing the same error. 我将SQL语句从日志复制到SQL查询,并且IntelliSense当然会抛出相同的错误。 I wonder if some SQL guru can shed some light on this. 我想知道是否有一些SQL专家可以对此有所了解。 See screenshots below. 请参见下面的屏幕截图。

SQL Code resulting in an exception SQL代码导致异常

Error 1 错误1

Error 2 错误2

Ok, looks like i figured it out while waiting endlessly for PSS. 好的,看起来我在无休止地等待PSS时发现了问题。

The issue I faced was related to the DB missing tables, I don't know how and why these tables are linked to changing the owner of a record, but I noticed the complaint about the missing tables when trying to upgrade the org to 7.03. 我遇到的问题与数据库丢失表有关,我不知道这些表如何以及为什么与更改记录的所有者相关联,但是我在尝试将组织升级到7.03时注意到有关丢失表的投诉。 Well actually, the tables are probably not related to the issue, its just that the DB was in an inconsistent state, and these tables were the reason I was not able to bring it back to 7.03. 好吧,实际上,这些表可能与问题无关,只是数据库处于不一致状态,而这些表正是我无法将其恢复至7.03的原因。 I basically carefully reviewed the upgrade log files. 我基本上仔细地检查了升级日志文件。 It failed when trying to create a View from a table that It could not find. 尝试从无法找到的表创建视图时失败。 The error was “object not found”. 错误是“找不到对象”。 There were a total of 4 tables. 共有4张桌子。 The upgrade log file didn't first report on all 4 tables because it stopped as soon as it found the first missing. 升级日志文件没有首先报告所有4个表,因为它在发现第一个丢失时就停止了。 So I grabbed the DB from a functional 7.03 Dynamics Org, found the tables, and created a Create script for each missing table. 因此,我从功能正常的7.03 Dynamics Org中获取了数据库,找到了表,并为每个丢失的表创建了一个Create脚本。 The critical part was that I needed to close and reopen deployment manager to allow the upgrade process to pick up the new tables. 关键部分是我需要关闭并重新打开Deployment Manager,以允许升级过程选择新表。 See script below. 请参见下面的脚本。 Once I created the 4 tables, the upgrade process was successfully able to create the required Views and the upgrade to 7.03 was successful. 一旦创建了4个表,升级过程就可以成功创建所需的视图,并且成功升级到7.03。 Upgrading the org to 7.03 resolved the issue. 将组织升级到7.03解决了该问题。

 /***** Table 1 SubscriptionStatisticsOutlookBase *****/ USE <DBName>_MSCRM GO SET ANSI_NULLS ON GO SET QUOTED_IDENTIFIER ON GO CREATE TABLE [dbo].[SubscriptionStatisticsOutlookBase](       [ObjectTypeCode] [int] NOT NULL,       [FullSyncRequired] [bit] NOT NULL,       [SubscriptionId] [uniqueidentifier] NOT NULL, CONSTRAINT [PK_SubscriptionStatisticsOutlookBase] PRIMARY KEY CLUSTERED (       [SubscriptionId] ASC,       [ObjectTypeCode] ASC )WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON, FILLFACTOR = 80) ON [PRIMARY] ) ON [PRIMARY] GO ALTER TABLE [dbo].[SubscriptionStatisticsOutlookBase] ADD  CONSTRAINT [DF_SubscriptionStatisticsOutlookBase_FullSyncRequired]  DEFAULT ((1)) FOR [FullSyncRequired] GO /******* Table 2 SubscriptionSyncEntryOfflineBase ******/ USE <DBName>_MSCRM GO SET ANSI_NULLS ON GO SET QUOTED_IDENTIFIER ON GO CREATE TABLE [dbo].[SubscriptionSyncEntryOfflineBase](       [ObjectTypeCode] [int] NOT NULL,       [VersionNumber] [bigint] NOT NULL,       [ObjectId] [uniqueidentifier] NOT NULL,       [SubscriptionId] [uniqueidentifier] NOT NULL,       [SyncState] [tinyint] NOT NULL, CONSTRAINT [PK_SubscriptionSyncEntryOfflineBase] PRIMARY KEY CLUSTERED (       [SubscriptionId] ASC,       [ObjectId] ASC,       [ObjectTypeCode] ASC )WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON, FILLFACTOR = 80) ON [PRIMARY] ) ON [PRIMARY] GO /***** Table 3 SubscriptionSyncEntryOutlookBase ****/ USE <DBName>_MSCRM GO SET ANSI_NULLS ON GO SET QUOTED_IDENTIFIER ON GO CREATE TABLE [dbo].[SubscriptionSyncEntryOutlookBase](       [SyncState] [tinyint] NOT NULL,       [ObjectTypeCode] [int] NOT NULL,       [ObjectId] [uniqueidentifier] NOT NULL,       [VersionNumber] [bigint] NOT NULL,       [SubscriptionId] [uniqueidentifier] NOT NULL, CONSTRAINT [PK_SubscriptionSyncEntryOutlookBase] PRIMARY KEY CLUSTERED (       [SubscriptionId] ASC,       [ObjectId] ASC,       [ObjectTypeCode] ASC )WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON, FILLFACTOR = 80) ON [PRIMARY] ) ON [PRIMARY] GO /****** Table 4 SubscriptionStatisticsOfflineBase *****/ USE <DBNAme>_MSCRM GO SET ANSI_NULLS ON GO SET QUOTED_IDENTIFIER ON GO CREATE TABLE [dbo].[SubscriptionStatisticsOfflineBase](       [FullSyncRequired] [bit] NOT NULL,       [SubscriptionId] [uniqueidentifier] NOT NULL,       [ObjectTypeCode] [int] NOT NULL, CONSTRAINT [PK_SubscriptionStatisticsOfflineBase] PRIMARY KEY CLUSTERED (       [SubscriptionId] ASC,       [ObjectTypeCode] ASC )WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON, FILLFACTOR = 80) ON [PRIMARY] ) ON [PRIMARY] GO ALTER TABLE [dbo].[SubscriptionStatisticsOfflineBase] ADD  CONSTRAINT [DF_SubscriptionStatisticsOfflineBase_FullSyncRequired]  DEFAULT ((1)) FOR [FullSyncRequired] GO 

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM