Alteryx Designer Desktop Discussions

Find answers, ask questions, and share expertise about Alteryx Designer Desktop and Intelligence Suite.

Dynamic Input Error

6 - Meteoroid



I am using the Dynamic Input tool to read multiple CSV files into my workflow; however, there are some files that create an error due to "a field was missing a closing quote in record...". Once that error occurs, it stops reading any further CSV files. 


I'm wondering, is it possible to change the settings so that it ignores that error and continues to read the remaining lines of the CSV file, along with any other CSV files that come after it?


Thanks in advance!!


17 - Castor
17 - Castor

Hi @lmosher 


I think that would be the case you should use a Batch Macro to read these files. 


In the Batch Macro you can actually give a special treatment to each of these cases of corrupted schema - you could even set something to skip these files.

There are some articles that explain this method



6 - Meteoroid

Hi @Thableaus


Thanks for your prompt response!


Here's what I've got so far per your suggestion. I've never used the Batch Macros before, so I'm not entirely sure how to progress from here. 


One of the links you posted talked about changing the names of the input; my issue deals with a single line in the CSV file that doesn't have a closing quotation. How do you go about setting the macro to skip the lines in the file with the corrupted schema?



17 - Castor
17 - Castor



In this case you don't use the Dynamic Input.


The macro needs to be built separately from where you're going to insert the File Paths (from the Directory Tool).


I will get you an example later, but if you carefully read the articles I posted, you will figure this out.



10 - Fireball

Using the "Text to Columns" tool is a lot more flexible than the "Input" tool, and then you can filter out the bad data and try to fix it.


Double Read the CSV file.jpg

In the "Input" tool you set the delimiter to "\0" for no delimiter, and in the "Text to Columns" tool you put in your real delimiter.


The "Input" tools configuration window:

Read in with no Delminter.jpg


The "Text to Columns" tools configuration window:

Text to Columns Tool.jpg

6 - Meteoroid

@darryl5280 this works perfectly! Thanks for the solution!!

7 - Meteor

On the options where it says " Ignore delimiters in", I changed this from "Quotes" to "None", and that seemed to fix this error as well.