+ Start a Discussion
Sourav PSourav P 

To get the prefix "000" in the text data type field

Hi,
I have a text field " Endos Count" which is a counter field. But the format of the count i need is, 001,002,003 etc. Now i am getting as 1,2 3. Can anyone suggest plz, how to get this type of format.
I just wrote the below formula, but its not working,
TEXT(VALUE(Endorsement_Count__c)+001)
Best Answer chosen by Sourav P
Tarun Khatri (TK)Tarun Khatri (TK)
Try using:
'00'+TEXT(VALUE(Endorsement_Count__c))

But in this case, it will always show 2 leading 0's in your field.

You can add more logic in it by adding IF conditions which checks if Endorsement count is greater than 9 and less than 100, add only one leading zero and so on.

-Thanks,
TK

Did this answer your question? If not, let me know what didn't work, or if so, please mark it solved.

All Answers

Suresh(Suri)Suresh(Suri)
Hi Sourav,

Try in your text formula field like
"000" & Endorsement_Count__c
Sourav PSourav P
Hi Suresh, Thanks, Let me try this.
You mean , like TEXT(VALUE("000" & Endorsement_Count__c)+001)
Tarun Khatri (TK)Tarun Khatri (TK)
Try using:
'00'+TEXT(VALUE(Endorsement_Count__c))

But in this case, it will always show 2 leading 0's in your field.

You can add more logic in it by adding IF conditions which checks if Endorsement count is greater than 9 and less than 100, add only one leading zero and so on.

-Thanks,
TK

Did this answer your question? If not, let me know what didn't work, or if so, please mark it solved.
This was selected as the best answer
Sourav PSourav P
Hi Tarun, The above didnt satisfied my need as its always show two zero.
But i try using the below with IF logic as suggested and it worked. Thanks