How to filter specific Custom Objects?
Hi all,
I record very specific events into Custom Objects linked to Leads. For example if a user has clicked on a specific link that I'd like to track, I'll create a Custom Object out of that event and this CO will include extra data than the one that Marketo holds in the Activity Log. (which is why I create a CO instead of using the Activity Log)
I'd like to be able to target COs that have specific properties based on the data that is in their fields, for example:
- Has CO
- dateTime is in timeframe Yesterday
- partnerURL is not empty
If I create a Smart List with this criteria and it generates a list of leads that are linked to COs that match this criteria. Then I send an email each day with a personalized message and the partnerURL link so that the user can click on it. To do this I fetch the size of the CO and then retrieve the last CO created for that user.
Except in some cases I have recorded multiple COs on the same day for a same user and only one of the COs really matches the criteria, and worst of all, the latest CO does NOT match the criteria. So when I build the email dynamically by fetching the last CO, the link doesn't work because that CO did not have a partnerURL.
Any idea how I can filter out the COs that don't match the criteria I used in the Smart List? The issue is that the Smart List fetches a list of Leads, whereas I should fetch a list of COs, and if possible only those that match my criteria.
Thanks for your help!
Thomas