I have a text file that I need to separate into about 250 columns. There are no delimiters that exist. (see pic below)
Is there a way to establish the field names/lengths outside of manually setting the field divisions and naming each field? I see the "Use Field Settings from File" option, but can't locate any instructions/examples on how that is used.
Ideally, I'd like to create a file with the field name and lengths and then use those values to parse the txt file.
Solved! Go to Solution.
I've used this technique in the past:
open your file and create 2 or 3 fields.
Save you file as a FLAT
Open the FLAT and you'll see the XML that you need.
Create a formula that concatenates all of the data together based upon a table of fields and lengths.
Update your xml and save. When you open the flat file, use the .FLAT as the metadata.
Done.
Thanks so much Marquee.. that saved me a ton of time and tedious work..
Is it possible to provide the Alteryx workflow for this?
Attached is a sample flat file that i edit in notepad to change the field names and field lengths..
the way it works is you open the "flat file" in notepad and set your field names and lengths(sample below)
once finished, save the file..then from Alteryx, setup your input for the text file you need to parse, and when prompted choose to import as a "flat file"
Then, when you get to the screen below, select "Use Field settings.. " option. Select the folder icon to the right and then choose the "flat file" that you updated from above as your template.
Once you select your file, Alteryx will use the field names and lengths to parse your source file. (see below)
Hope that helps..
I do not see an attached example file.
This would be helpful.
User | Count |
---|---|
18 | |
14 | |
13 | |
9 | |
8 |