• MaryP
  • NEWBIE
  • 0 Points
  • Member since 2011

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 0
    Questions
  • 1
    Replies

I'm using the Campaign Membership Manager 1.0 app by Force.com Labs. Unfortunately, it seems that having mutli-currency enabled is causing a problem with the code. 

 

Invalid field CurrencyIsoCode for SObject CampaignMember 

 

I attempted to resolve this problem myself by updating the query in the app controller by adding the CurrencyIsoCode to both the CampaignMember and Campaign queries. But, I get this error when I try to save in Eclipse:

 

No such column 'CurrencyIsoCode' on entity 'CampaignMember'.

 

I have double checked the spelling and actually copied the api name from the Setup > Campaign Members field listing. So, I know that it exists on the CampaignMember object. I'm just confused as to why it won't let me include that field.

 

It's pretty pointless because we aren't using the Multi-Currency field. We enabled it in the past because a consultant told us to but we are only using dollars.

 

Here is the query that I am updating:

 

 

        for( CampaignMember cm: [ Select Id, CurrencyIsoCode, LeadId, Lead.Company, Lead.Email, Lead.FirstName, Lead.LastName, Lead.OwnerId, Lead.City, ContactId, 
        							Contact.Account.Name, Contact.Email, Contact.FirstName, Contact.LastName, Contact.OwnerId, Contact.MailingCity, Status
        							from CampaignMember 
        							WHERE CampaignId =: selectedCampaign AND ( Contact.OwnerID =: userName OR Lead.OwnerID =: userName ) 
        							ORDER BY Lead.LastName, Contact.LastName ] ){
        								
            this.campaignMemberList.add( new MyCampaignMember( cm ) );
        }
        

 

Any tips as to why this may be happening or how I can reformat the query?