Alteryx Designer Knowledge Base

Definitive answers from Designer experts.
Don't forget to submit your entry for the Excellence Awards by October 30! | Need more information about the program? Check out the blog here

Too many fields in row x when reading in a .csv file

Alteryx
Alteryx
Created

These methods should work in most versions of Alteryx. 

 

One of the most common issues we see from clients trying to read in a .csv file is that they are receiving an error starting “Too many fields in row x”, and because of this Alteryx can’t read in the file.

 

TooManyFields_Error.jpg

 

There are a couple of different ways you can resolve this error.

 

First, in the Input Data tool, you can tell Alteryx to treat read errors as warnings to allow the file to be read in.

 

ReadError_AsWarningCheckBox.jpg

 

This will change the Error to a Warning so that Alteryx can read in the file so you can investigate.

 

Error_AsWarning.jpg

 

The other method is to read the file in with no delimiter. You can do this by changing the delimiter in the Input Data tool to \0.

 

No Delimiter.jpg

 

Once you have your data parsed back out into its fields, you can use the Dynamic Rename tool to correct your field names, a select tool to remove the original field, and a simple Trim() function to remove the extra delimiter from your data.

 Workflow_Screenshot.jpg

This process is illustrated in the attached workflow, created in version 10.1.

 

 

Attachments
Comments
7 - Meteor

Thanks for sharing this. However I think the issue many of us are facing is that we have that unncessery comma not in the last field but let's say in the 2nd column. Thus it separates the columns incorrectly and your solution would only work for a case where the comma is only at the last column