You need to sign in to do that
Don't have an account?

Getting Person account properties from a User
if I have a user that has "plugged" a person account throught the User.ContactId,
Account a = handleAccount(create, u, attributes); // a gets an account object
Id accountId = a.Id;
......
User U ....
U.ContactId = [select PersonContactId FROM account where ID =: accountId].PersonContactId;
How can I do to refer to all the account properties from User? Is there something like U.ContactId__r.personemail?
Thanks
Account a = handleAccount(create, u, attributes); // a gets an account object
Id accountId = a.Id;
......
User U ....
U.ContactId = [select PersonContactId FROM account where ID =: accountId].PersonContactId;
How can I do to refer to all the account properties from User? Is there something like U.ContactId__r.personemail?
Thanks
Since the ContactID is not a true reference ,you will have to query the information back for users. Please mark this post as solved if it helps.
Best Regards,
Nagendra.P