Hello forum,
Im making a form application that inserts a decimal number into a MySQL database. I’ve put regional settings off and changed the decimal separator to a comma.
When I try to insert the value I get the error "Incorrect decimal value for ‘1000,25’ ".
Stuff I’ve tried:
Setting the comma to a period in the Decimal Separator.
OnBeforeInsert try to use the php functions str_replace and number_format to replace the comma with a period.
Tried setting the decimals to doubles, which leads to a truncation of the data before the comma. 1000,00 became 1,00.
Tried setting the fields to currency, which leads to the same error.
No matter what I try it still tries to insert a comma when MySQL expects a dot as separator.
I’m using UTF-8 and English(United States) as regional.
UPDATE: Printing the value even gave 1000.25, but the pdo-mysql statement still tries to insert 1000,25.
Please help