distal-attribute
distal-attribute
distal-attribute
distal-attribute

Cutting decimals

User, date Message
Written by pangaea
6 years ago
Category: Import/Export
4 posts since Fri, 07 Nov 08
Hi,

i have a problem. when i import decimal numers
like 123,456789 then ist cutted to 123 after import in the database.

when i export i see ith right as 123,456789 with comma. looks exactly than my csv file.

Any idea?

Harald
Written by rosenfield
6 years ago
127 posts since Wed, 24 Jan 07
How do you "import" them?

Which column type are you using? It has to be able to accommodate real numbers, meaning in MySQL it must be "float", "double" or "decimal". Maybe the column type you've chosen can only contain integers?
Written by pangaea
6 years ago
4 posts since Fri, 07 Nov 08
coulm type double.
when i type in manually into the db field thre is no problem.

i import as csv, determined by semikolon.
Best regards

Harald
Written by pangaea
6 years ago
4 posts since Fri, 07 Nov 08
found the bug.

when i work with heidi i have to type a "," for decimals

when i import i have to use a "."

not satisfies me....

best regards
harald
Written by rosenfield
6 years ago
127 posts since Wed, 24 Jan 07
may be related to http://bugs.heidisql.com/868.
Written by pangaea
6 years ago
4 posts since Fri, 07 Nov 08
load the latest release 1999 and it dont fix the problem

Best regards

Harald
Written by AliG
3 years ago
20 posts since Tue, 12 Jan 10
Hi,
I have similar "issue".

When I insert data manually (into data tab) and I insert eg. "1.22", it inserts only "1" (my local decimal separator is "," and mysql decimal separator is ".")

Maybe it could first check if the users uses dot or comma (check last delimiter)
Written by ansgar
3 years ago
4936 posts since Fri, 07 Apr 06
That's not an option if you have the dot as the thousand separator in your language. Just use your local number format and you're done.
Written by AliG
3 years ago
20 posts since Tue, 12 Jan 10
well, I copy&paste it from source with the dot ... I thought that it would be easy to automatically convert the "." to ",", but I understand that it is not possible due to different local settings :(
Written by ansgar
3 years ago
4936 posts since Fri, 07 Apr 06
Yes, I could easily ignore the local settings of each user but I think this is not what the majority of users expect from HeidiSQL. Indeed, there may be quite a few preferring the english/american number format, but this is still subjective and I'm not going to ignore users from other countries.
Written by Olaf789
3 years ago
15 posts since Mon, 13 Dec 10
Just a friendly reminder smile:
Please thread very carefully here. I have experienced nothing but griefunhappyfrom this subject. You think doubles are a problem? Wait till you get dates. And what happens when you work in international environments en you get appended sets where parts have '.' and others parts have ','. There seems to be no right solution. Satisfying one will immediately cause problems somewhere else.

Personally I would hail the day if ISO came to it senses and decided on one single format.

Good luck
smile
 

Please login to leave a reply, or register at first.