+ Start a Discussion
sd2008sd2008 

Question: Comparison arguments must be compatible types: Double, String?

I got a "Comparison arguments must be compatible types: Double, String" error message

 

the Fn_outcall.saveobj(str) function takes a string parameter.

here is the code:

 

trigger OriUpdateTrigger on Ori__c (after insert, after update) {

  

 for(Ori__c o: Trigger.New){

 

  if (o.AID__c != null && o.AID__c <>''){

   String str = String.valueOf(o.AID__c);

   fn_Outcall.Saveobj(str);

 

  }

 }

}

JimRaeJimRae

Your issue is probably with this evaluation:

 

o.AID__c <>''

 

 If your field AID__c is a numeric, I don't think you need to evaluate it for '', it should either be a number, or null.

 

 

sd2008sd2008
thanks