我有从C#中看看更新的最佳方法/检索实体。 。我已经通过MSDN文档,但读不确定该走哪条路/时,使用这两种方法
I'm having a look at the best way of updating/retrieve entities from within C#. I've had a read through the MSDN documentation but unsure which way to go/when to use either method.
所以,我的问题:
我应该使用:
- IOrganizationService.Update()更新和直接的实体;或
-
IOrganization.Execute()并创建一个更新请求
- IOrganizationService.Update() and update the entity directly; or
IOrganization.Execute() and create an update request
如果答案是这取决于',有什么情况需要哪种方法?
And if the answer is 'it depends', what situation warrants which method?
感谢
推荐答案第一,执行一个UpdateRequest的产生同样的结果。
First of all both Update and Execute of an UpdateRequest produce the same result.
的主要区别在于,一个UpdateRequest可以使用ExecuteMultipleRequest分批
The main difference is that an UpdateRequest can be batched using the ExecuteMultipleRequest
更多推荐
IOrganizationService更新实体正确的方法
发布评论