You need to sign in to do that
Don't have an account?
force shahid
Updation Error in Contact Object while updating record through custom object
Hi Friends,
I have a problem on updation [rpcess. I am updating contact records through custom object. And I write a method for updation. If the custom object field is empty then no need to update contact field.
But this scenario is different in MQL_Date field. If MQL_Date field is having a value in contact object then no need to update this field with custom object MQL_date field.
But its not working.
The MQL_Date field of contact object is updated with custom object MQL_Date field field.
My Code is :
c1.Became_an_MQL_Lead_Date__c = isValidInputDate( c1.Became_an_MQL_Lead_Date__c)? c1.Became_an_MQL_Lead_Date__c : customObjRecord.MQL_Date__c;
Method is :
public static boolean isValidInputDate(Datetime D) {
if(D != null ) {
return true;
}
return false;
}
Thanks in Advance,
Shahid.
I have a problem on updation [rpcess. I am updating contact records through custom object. And I write a method for updation. If the custom object field is empty then no need to update contact field.
But this scenario is different in MQL_Date field. If MQL_Date field is having a value in contact object then no need to update this field with custom object MQL_date field.
But its not working.
The MQL_Date field of contact object is updated with custom object MQL_Date field field.
My Code is :
c1.Became_an_MQL_Lead_Date__c = isValidInputDate( c1.Became_an_MQL_Lead_Date__c)? c1.Became_an_MQL_Lead_Date__c : customObjRecord.MQL_Date__c;
Method is :
public static boolean isValidInputDate(Datetime D) {
if(D != null ) {
return true;
}
return false;
}
Thanks in Advance,
Shahid.
c1.Became_an_MQL_Lead_Date__c = NOT(ISBLANK( c1.Became_an_MQL_Lead_Date__c))? customObjRecord.MQL_Date__c : c1.Became_an_MQL_Lead_Date__c ;
No need of method "isValidInputDate"
I mean you mentioned "The MQL_Date field of contact object is updated with custom object MQL_Date field field." What happens when Contact has 5 child records and they all have different MQL_Date field on each. Which one should mirror the Contact's MQL_Date field?