Feature-like bug in File reader: wrong autodetection of missing value pattern

I have a CSV file:
‘country’; ‘cus_code’
‘UK’;‘K118’
‘IT’;‘K118’
‘DE’;‘44558’
‘DE’;‘44556’
‘DE’;‘11992’

Using file reader node to read it:
image

What! Missing values? Maybe changing format to string helps?
image

Nope. Turns out, File reader wrongly autodetected the missing value string:
image

I guess this was intended as feature, however brings a little, unexpected bug. :slight_smile: It appears that if there is one non-number value in number column, it is assumed as missing value pattern.

1 Like

I can assume that integer field cannot have K118 filler for missing. It is string type

Well, it is string in the CSV, enclosed by quotes. Anyhow, KNIME should not be guessing “K118” as missing value pattern, it does not make sense in any case.

I would recommend to use File Reader node instead CSV Reader. It is more robust and allow you to assign a field type using header in preview.

Hello @Experimenter,

I have checked it and feels wrong to do such auto detection. Have opened up a ticket and let’s see. (Internal reference: AP-15491)

However to avoid this you can use new CSV Reader (Labs) or (also new) Simple File Reader node.

Br,
Ivan

1 Like

Thank you. Yeah, I checked that Simple reader handles the matter correctly. Just lately I am using drag-n-dropping file from Windows Explorer to the Knime workflow, and File reader is the default option offered.

1 Like

This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.