无法从关系查询中引用用户名

Failing to reference name of user from relationship query

我正在尝试通过此查询为 Salesforce 中的测试用户获取 permissionSetGroupComponents。

SELECT AssigneeId, IsActive, ExpirationDate, PermissionSetGroupId, PermissionSetId FROM PermissionSetAssignment WHERE User.FirstName = 'Test'

但是当我 运行 我得到这个错误。

PermissionSetAssignment WHERE User.FirstName = 'Test'
                          ^
ERROR at Row:1:Column:119
Didn't understand relationship 'User' in field path. If you are attempting to use a custom relationship, be sure to append the '__r' after the custom relationship name. Please reference your WSDL or the describe call for the appropriate names.

根据 API 文档,这两个对象之间存在关系,所以我不明白为什么找不到关系。 https://developer.salesforce.com/docs/atlas.en-us.api.meta/api/sforce_api_objects_permissionsetassignment.htm

User 不是关系的名称。关系字段是AssigneeId,所以关系字段是Assignee:

SELECT AssigneeId, IsActive, ExpirationDate, PermissionSetGroupId, PermissionSetId 
FROM PermissionSetAssignment 
WHERE Assignee.FirstName = 'Test'