Re: Is there a way to get an Account Owner Job Title and Phone Number token?

Anonymous
Not applicable

Is there a way to get an Account Owner Job Title and Phone Number token?

Currently, there are company tokens for Account Owner First Name, Last Name and Email Address, but Marketo does not provide tokens for the Account Owner Job Title or Phone Number.   There are at least 2 Ideas for this:
 Since this has still not been implemented it seems like "Maybe One Day" is the correct Status :0(

In the meantime, is there a way to create a workaround?  We tried to create formula fields on the Account record for Account Owner Job Title and Account Owner Phone Number, but we weren't able to reference those fields in the user record.  Maybe that's why Marketo hasn't been able to do this yet? 


Tags (1)
5 REPLIES 5
Itay_Billet4
Level 8

Re: Is there a way to get an Account Owner Job Title and Phone Number token?

Elliott, I know that it's not possible to create formulas on the owner fields in SFDC (you'll have to create a trigger that will copy the owner field into another custom lookup field, and then create formula fields to Job title and Phone). Fortunately, SFDC are going to fix this in the summer '13 release: https://success.salesforce.com/ideaview?id=08730000000BrqaAAC
Anonymous
Not applicable

Re: Is there a way to get an Account Owner Job Title and Phone Number token?

I use custom fields for job title and phone number. You could create change data flows for each of the account owners to set these fields initially and then change them to trigger campaigns in the event the account owner is changed. It may be a bit time consuming to set up if you have a lot of reps, but will solve your problem. 

I agree it would be nice if they were part of the system!
Anonymous
Not applicable

Re: Is there a way to get an Account Owner Job Title and Phone Number token?

Thanks Itay - that's great news!  I wonder if this change will enable Marketo to see these fields now, or if that is a different issue? 

Thanks Amanda for your workaround, which I may implement if these fields are not going to be made available via tokens in the near future.
Itay_Billet4
Level 8

Re: Is there a way to get an Account Owner Job Title and Phone Number token?

I think you'll have to create those fields in SF (under Account), and then they'll be available to use in Marketo. Marketo will be able to see the fields, it's just a matter of poopulating them with the information.
Anonymous
Not applicable

Re: Is there a way to get an Account Owner Job Title and Phone Number token?

Create a custom field called "Owner Copy"

Here's the trigger:

trigger accountOwnerCopy on Account (before Insert, before Update) {
 
    // handle arbitrary number of Accounts
    for(Account x : Trigger.New){
 
        // Has Owner changed?
        if (x.OwnerID != x.Owner_Copy__c) {
 
            // check that owner is a user (not a queue)
            if( ((String)x.OwnerId).substring(0,3) == '005' ){
                x.Owner_Copy__c = x.OwnerId;
            }
 
            else{
            // in case of Queue we clear out our copy field
                x.Owner_Copy__c = null;
            }
        }
    }
}


=====

You will also need this test class

@isTest
public with sharing class TriggerTestOwnerCopy {
 
    static testMethod void testAccountOwnerCopy() {
         // Grab two Users
        User[] users = [select Id from User where IsActive= true limit 3];
        User u1 = users[0];
        User u2 = users[2];
 
        // Create a Account
        System.debug('Creating Account');
        Account x1 = new Account(Name='Test', OwnerId = u1.Id);
        insert x1;
 
        // Test: Owner_Link should be set to user 1
        Account x2 = [select id, OwnerId, Owner_Copy__c from Account where Id = :x1.Id];
        System.assertEquals(u1.Id, x2.OwnerId);
        System.assertEquals(u1.Id, x2.Owner_Copy__c);
 
        // Modify Owner
        x2.OwnerId = u2.Id;
        update x2;
 
        // Test: Owner_Link should be set to user 2
        Account x3 = [select id, OwnerId, Owner_Copy__c from Account where Id = :x2.Id];
        System.assertEquals(u2.Id, x3.OwnerId);
        System.assertEquals(u2.Id, x3.Owner_Copy__c);
    }
    
   
}