Task object, reference the account of a contact on a task

I am trying to pull in all tasks that are related to an account, however, a good number of tasks are associated to a contact related to the account and don’t have an account listed with the task. I saw some other posts about this but I was wondering if there is anyway to drill into the WhoId field on the task and pull the account that the contact is associated with? Or if you have any other work-arounds, I would love to know more! I tried using the child relationships object, but our reps would like the ability to create a new record inline and have these tasks in a table view

Hi Megan

When you create a task you have the opportunity to select Contact or Lead = WhoId and Related to = WhatId

The Contact record has an AccountId field and if the contact is linked to an Account then this will be populated with the AccountId.

You can then filter on the Task object by AccountId which will display all task for the Account and Contacts linked to the AccountId.

I have created a quick page with the filters you can look at:

Create a new page and paste the below XML.













































































































Another idea would be to create a model on contacts and put a condition on it to only allow contacts associated with the account(s) you want to display associated tasks. Then on your task model, you can create a condition that only allows tasks With WhoId’s that are in your contact model. You would still need the condition to display tasks linked directly to the account as wel, so set your model condition logic to “1 or 2”. Then it should display all tasks associated with the account and tasks associated with contacts that are associated with the account.

Yup.  Greg is right! 

Thank you! I tried both Gregg and Raymond’s method and I was more along the track Raymond was going, just didn’t think to reference the contact id when I created my filters.

rrrr