【问题标题】:I'm new in Salesforce and have question regarding SOQL Query in salesforce我是 Salesforce 的新手,对 Salesforce 中的 SOQL 查询有疑问
【发布时间】:2021-08-26 14:28:46
【问题描述】:

编写 SOQL 查询以使用记录 ID 从 Account 获取联系人。

【问题讨论】:

  • 请澄清您的具体问题或提供其他详细信息以准确突出您的需求。正如目前所写的那样,很难准确地说出你在问什么。
  • 我很困惑,因为我知道这个查询 [select id, name,(select id,AccountId from Contacts) from Account where...] 但是我应该在 WHERE 子句中使用什么?这是我的问题。希望你能理解。
  • 你读过documentation吗?

标签: salesforce apex soql


【解决方案1】:

您可以使用以下查询从帐户中获取联系信息:

SELECT Id, Name, (SELECT AccountId, Name, Email  FROM Contacts) 
FROM Account WHERE Id = 'record Id'

【讨论】:

    猜你喜欢
    • 2022-01-14
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2010-12-03
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多