Advent of Code is back! Unwrap daily challenges to sharpen your Alteryx skills and earn badges along the way! Learn more now.
Free Trial

Alteryx Designer Desktop Discussions

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

Importing a Fixed Width .txt file

NRD
8 - Asteroid

Hi All,

 

I am having some trouble when importing a fixed width text file using the 'use field settings from file' function.

 

I have the lengths of the fields in the flat file that I am using for the specifications however I need to tell Alteryx where to begin reading the field. The place to 'start' the read.

 

For example some of my fields are not the full 'length' specified in the flat file so they are not parsing out properly.

 

My second field 'Company Code' may have a length of '5' but I want alteryx to begin reading this field on the say '12' character instead of right after the first field is written in. Alteryx begins counting at 1 instead of 0 which could be the issue as well.

 

Does Alteryx have the capability of doing this?

 

 

1 REPLY 1
mbarone
16 - Nebula
16 - Nebula

Fixed width means exactly that - it will adhere to your flat file settings, starting at position 1.  

So your PRODBASIC field will go from position 1 to 10 (10 character length).

Company Code will go from position 11 to position 15 (5 character length).

and so on.

 

So two choices.  One is to increase the length of of PRODBASIC to 11.  The other is to add a field that is exactly length 1 (1 character long).  Maybe name it "PLACEHOLDER" and then de-select it with a select tool after the input tool.

Labels
Top Solution Authors