praneethgb / google-refine

Automatically exported from code.google.com/p/google-refine
Other
0 stars 0 forks source link

Refine automatically attempts to parse a string containing "E" as e notation #511

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
I noticed that a column containing string codes such as "5E0" and "5E1", had 
cells parsed as numbers "50" and "51".

I can only assume that Refine is attempting to parse the "E" as an exponent for 
an integer.

Not sure if this is deliberate, but it destroys data.

Original issue reported on code.google.com by danpaulsmith on 20 Dec 2011 at 12:23

GoogleCodeExporter commented 8 years ago
Did you have a checkmark for the option to parse cells containing numbers 
during the project creation preview ?  That probably needed to be unchecked.

Original comment by thadguidry on 20 Dec 2011 at 2:20

GoogleCodeExporter commented 8 years ago
Yes, probably, but if I have 5 or 10 other columns containing numbers, wouldn't 
I want to leave the box checked?

Original comment by danpaulsmith on 20 Dec 2011 at 2:31

GoogleCodeExporter commented 8 years ago
NOT on the import.  Easier to change the columns type AFTER the import with 
Edit cells -> Common tranforms -> to number.  Or with a GREL expression 
toNumber(value)

Original comment by thadguidry on 20 Dec 2011 at 2:38

GoogleCodeExporter commented 8 years ago
Unfortunately, not all importers have the ability to turn off data type 
guessing/conversion.  There are two good reasons to have it off (and we'll 
probably be changing the default as well making sure all importers support 
this): 1) it's slow - the algorithm is try to convert to date, try to convert 
to float, try to convert to integer, try to ..., well, you get the idea and 2) 
it's irreversible.

The flip side of this is that it's tedious to convert lots of columns after 
import, so we probably need a better way to convert all columns or convert a 
bunch of columns.

Original comment by tfmorris on 20 Dec 2011 at 3:44

GoogleCodeExporter commented 8 years ago

Original comment by tfmorris on 20 Dec 2011 at 3:44