![](/img/trans.png)
[英]How to setup Salesforce credentials in Rails using the restforce gem?
[英]How to get all associated data with the salesforce account object in ruby on rails using restforce gem
我试图使用restforce REST Api从salesforce提取所有用户数据。我有salesforce帐户对象。 现在,我想获取与此帐户对象相关的所有数据。
这是一个多步骤过程:
获取对象的列:
# get the describe for the Account object account_columns = client.describe('Account') # => { ... }
运行普通查询:
accounts = client.query("select #{account_columns} from Account where Id = 'someid'") # => #<Restforce::Collection> account = accounts.first # => #<Restforce::SObject>
访问相关对象:
account.Owner
来源-https: //github.com/ejholmes/restforce
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.