You need to sign in to do that
Don't have an account?
jojoforce
User and UserTerritory Join?
Is there a way to show the Territory.Name field and the User.Firstname, User.LastName via SOQL?
I tried the following code, but it doesn't seem to work. Thanks in advance for any help.
SELECT TerritoryId.Name, UserId.FirstName,UserId.LastName FROM UserTerritory
I agree. I was able to get this to work though. I used the Map<String, Object> and basically used the Key Value as their join condition.
Please note: This is just partial coding... but you get the idea.
Something like that.. and then for calling them I used something like the below to be able to display the record\
All Answers
Hi,
can't access userid.lastname and userid.firstname from Userterritory. we can get the userid and need to Query again .
Regards,
VNath.
I agree. I was able to get this to work though. I used the Map<String, Object> and basically used the Key Value as their join condition.
Please note: This is just partial coding... but you get the idea.
Something like that.. and then for calling them I used something like the below to be able to display the record\