Field value in form view is different than the same field in email template

This is interesting. I have a client generating a quote in a form and gets a different value for a field when he prints it out on the email template for the exact same field.

Does use of the email template round the value or something? (see Total Mileage field)


image

Total shipping is also different.

1 Like

Yes, total shipping is a calculation based on mileage.

I certainly wouldn’t think so.

@Daisy_Ramirez
May I ask what are the column types and how those numbers are calculated? I mean expression-wise

1 Like

Here are the two calculations for column types decimal:

vir_distance:
DISTANCE(LOOKUP([Starting Point],“US Zip Codes”,“Zip”,“Geopoint”),LOOKUP([Destination],“US Zip Codes”,“Zip”,“Geopoint”))

vir_mileage:
IF(OR(ISBLANK(LOOKUP([Starting Point],“US Zip Codes”,“Zip”,“City State”)),ISBLANK(LOOKUP([Destination],“US Zip Codes”,“Zip”,“City State”))),
0,([vir_distance]*0.621371))

@Daisy_Ramirez
Firstly, you don’t need 2 virtual columns to calculate this. Secondly, DISTANCE(…) expression returns the value as a Number/Integer, not a Decimal. Therefore, you can omit the [vir_distance] column and go on with [vir_mileage] column alone with this:

IF(
	OR(
		ISBLANK(LOOKUP([Starting Point],“US Zip Codes”,“Zip”,“City State”)),
		ISBLANK(LOOKUP([Destination],“US Zip Codes”,“Zip”,“City State”))
	),0.00,
	TRUE,
	DISTANCE(
		LOOKUP([Starting Point],“US Zip Codes”,“Zip”,“Geopoint”),
		LOOKUP([Destination],“US Zip Codes”,“Zip”,“Geopoint”)
	)*0.621371
)
1 Like