You need to sign in to do that
Don't have an account?
Deanna Aaron 4
Help: Field is removing additional 0's after decimal.
Hi there,
I have a geolocation field capturing latitude and longitude. There's a requirement to capture at least 6 digits after the decimal. I have a validation rule that works (yay!), but the fields seems to remove extra zeros after the decimal after saving (which we don't want).
For example, 12.123400 (should keep the extra zeros), but when saved, but it changes to 12.1234
Validation rule:
AND(
NOT(ISBLANK( Service_Coordinates__c )),
OR(
(((LEN(RIGHT(TEXT( Service_Coordinates__Longitude__s ), LEN(TEXT( Service_Coordinates__Longitude__s )) - FIND(".", TEXT( Service_Coordinates__Longitude__s )))) < 6)))
||
(LEN(RIGHT(TEXT( Service_Coordinates__Latitude__s ), LEN(TEXT( Service_Coordinates__Latitude__s )) - FIND(".", TEXT( Service_Coordinates__Latitude__s )))) < 6)
)
)
Thank you for your help!
I have a geolocation field capturing latitude and longitude. There's a requirement to capture at least 6 digits after the decimal. I have a validation rule that works (yay!), but the fields seems to remove extra zeros after the decimal after saving (which we don't want).
For example, 12.123400 (should keep the extra zeros), but when saved, but it changes to 12.1234
Validation rule:
AND(
NOT(ISBLANK( Service_Coordinates__c )),
OR(
(((LEN(RIGHT(TEXT( Service_Coordinates__Longitude__s ), LEN(TEXT( Service_Coordinates__Longitude__s )) - FIND(".", TEXT( Service_Coordinates__Longitude__s )))) < 6)))
||
(LEN(RIGHT(TEXT( Service_Coordinates__Latitude__s ), LEN(TEXT( Service_Coordinates__Latitude__s )) - FIND(".", TEXT( Service_Coordinates__Latitude__s )))) < 6)
)
)
Thank you for your help!
Recommend trying approach mentioned in https://salesforce.stackexchange.com/questions/25114/how-to-format-a-currency-or-decimal-value-without-rounding?rq=1
>Create a formula field of type currency.
>The formula should be Floor(YourfieldGoesHere)
>Add the formula to the page layout(s)
Also see https://salesforce.stackexchange.com/questions/289201/how-to-render-a-currency-field-with-decimal-places-as-specified-on-the-custom-fi
If this information helps, please mark the answer as best. Thank you