Insert non-English decimal points in mysql

后端 未结 4 2045
孤独总比滥情好
孤独总比滥情好 2020-12-07 02:33

How can you make mysql understand non-English decimal points in integer/float fields?

setLocale(LC_ALL, \'da_DK.ISO-8859-1\');

eg:

4条回答
  •  难免孤独
    2020-12-07 02:39

    One of the reasons you can't do that is that the comma , is used for separating field-values in INSERT statements.

    INSERT INTO a(b,c) VALUES (3,4,5) would be ambiguous.

    Should it result into b=3.4 , c=5 or b=3 , c=4.5 ?

提交回复
热议问题