Hi All,
Trying to build a batch macro to read all the files in a folder. Currently we have 59 files. The macro appears to be set up correctly with the action too, control tool and macro output. See image.
When I run the macro in my workflow, I receive the following error: "Record #60: Tool #2: Too many fields in record #1". Any idea what is going on here? Is it breaking because it is trying to read in a non-existent record?
@RichD is the macro trying to read .csv files?
Yes, the file type is "Microsoft Excel Comma Separated Values File"
@RichD You might need to change the settings in the input tool like below, then using the text-to-colum tool split the file based on the delimiter
What is strange is that I have it set up and it seems to be working on my machine (I built this a few years ago). I am helping a co-worker who wants to connect to the exact same data set, he is the one getting the error. He is on a trial license as we try to get him a full license (does that have anything to do with it?). Any thoughts why mine would work and he gets an error? We went step by step on his machine and set it up like mine (or course changing things to his folders/path/workflow), we copied mine a version of mine and updated it on his machine.... same error every time.
For input configuration I have:
File format =CSV
Delimiters = .
Field Length 254
Ignore Delimiters in = Quotes
@RichD I believe one of the file may be having different column structure, since you have 59 files run the files as batch (10 files at a time) through your batch macro and find out which file has the different structure
Thank you for you responses. I just connected with my co-worker. I am not sure why this worked, but when he changed the configuration ( check marked ) "Treat Errors and Warning" box it is now working for him. What is strange is that on my macro i do not have that checked and it works. We are both reading from the exact same location/files... somehow that small difference mattered...?
I don't totally understand why that has worked, but it seems to be working.
Thank you again for your messages!!
"Treat errors as warnings" means that if it cannot download a record, it will just skip it. You may not get all necessary data with that option. It is likely that it is related to AMP engine that will be turned on by default on his Alteryx and may not have been on when you built the workflow originally in your version. I've run into this several times with CSV files and checking the settings in the highlighted boxes will usually fix it when using AMP engine. You should ask him to try this.