Salesforce API 帐户创建
我们已经为 Salesforce 提供的 WSDL 文件创建了 C# 类。
生成的大多数类都是实体类,但似乎您没有任何方法可以调用,例如 CreateAccount 或 UpdateAccount。
这是正确的吗?您是否使用查询直接执行所有数据操作?
We've created C# classes for the WSDL file provided by Salesforce.
Most of the classes generated are entity classes, but it seems you don't have any methods to call such as CreateAccount or UpdateAccount.
Is that correct? Do you use a query to do all data manipulation directly?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
Salesforce 没有为每个对象提供单独的创建方法,而是提供了通用的创建方法,该方法接受通用对象的输入,该通用对象的类型可以是客户或联系人或任何自定义对象。
Instead of having separate create methods for each of the object, Salesforce provides a generic method of create which accepts input of generic object which can be of type account or contact or any custom object.
是的,这是正确的。这些对象中没有方法,所有操作都将使用它们的 api(Web 服务)来完成。
这里是一些 Java 示例代码和 C#
Yes, that is correct. You have no methods in those objects and all operations are to be done using their api (web services).
Here is some sample code in Java and C#
大多数类,如帐户、联系人等实际上只是通过网络传输的数据结构。 SforceService(如果您使用的是 Web 引用,不确定使用 WCF 调用该类)是使用它们执行操作的入口点,例如,您可以将帐户列表传递给 create 方法以在其上创建它们在 salesforce 方面,Web 服务 API 文档。
查询是只读的,您无法通过查询调用进行更改。
Most of the classes, like Account, Contact etc are really just data structures that go over the wire. The SforceService (if you're using web reference, not sure what the class is called with WCF), is the entry point for doing things with them, you can for example pass a list of Accounts to the create method to have them created on the salesforce side, there's a number of examples in the web services API docs.
Query is readonly only, you can't make changes via the query call.