Bug #75920
closedExtbase generic persistence casting float value to string causes wrong values if system locale is german
0%
Description
When setting a float property to 45.5 and persisting it via extbase on a system with locale=de the resulting string will be 45,5, that results in a stored value of 45.0 in the database.
this should be taken into account explicitly in the ObjectMapper::getPlainValue method.
If the input is of type float, we may have to string replace comma by dots or use some Utility class to cast the float value.
number_format($value, $precision, ".", "") could also do the job, to get the precision the sql would have to be evaluated when building the column map, so maybe str_replace(",", ".", (string) $value) would be the easiest solution.
My system runs php5.6 and system locale is de_DE.UTF-8
I will install the german locale also on production machine to enable german date formats etc. So this is gonna be a problem.