Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
anil Kumar

Formula field to calculate fields completeness

Hi All,

Name : 30%
Email: 25%
Phone: 25%
DOB: 10%
Thanks,
Best Answer chosen by anil Kumar
ravi soni
Hi anil kumar,

```IF( NOT(ISBLANK( LastName )),0.30, 0)+
IF( NOT(ISBLANK(Email)),0.25, 0) +
IF( NOT(ISBLANK(Phone)),0.25, 0) +
IF( NOT(ISBLANK( Birthdate )),0.10, 0)```

Please let me know, If it's help.

sachinarorasf
Hi anil Kumar,

(If( Name , 30, 0)+ If( Email , 25, 0)+ If( Phone , 25, 0) + If( Address , 10, 0) + If( DOB, 10, 0))

https://developer.salesforce.com/forums/?id=9060G000000Xdn3QAC

I hope you find the above solution helpful. If it does, please mark it as Best Answer to help others too.

Thanks and Regards,
Sachin Arora
www.sachinsf.com
anil Kumar
Hi Sachin,

Thank you for the responce. I have tried above formula with return type of Number and Percentage. I am getting beloe syntax erroe.

Incorrect parameter type for function 'IF()'. Expected Boolean, received Text

Thanks,
ravi soni
Hi anil kumar,

```IF( NOT(ISBLANK( LastName )),0.30, 0)+
IF( NOT(ISBLANK(Email)),0.25, 0) +
IF( NOT(ISBLANK(Phone)),0.25, 0) +
IF( NOT(ISBLANK( Birthdate )),0.10, 0)```

Please let me know, If it's help.
This was selected as the best answer
anil Kumar
Thank you Soni. This worked for me.