In case you missed the announcement: The Alteryx One Fall Release is here! Learn more about the new features and capabilities here
ACT NOW: The Alteryx team will be retiring support for Community account recovery and Community email-change requests after December 31, 2025. Make sure to check your account preferences in my.alteryx to make sure you have filled out your security questions. Learn more here
Start Free Trial

Alteryx Designer Desktop Discussions

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

Read data from a txt file and need to process data based on header records

motadikela
5 - Atom

Hi Community,

 

I am new to alteryx and trying to find a solution for my problem.

 

I have a text file with data as shown in the attached file sample_input_file.

 

I need to read the part of header value and need to append to the below rows till a new header is available.

 

Thanks in Advance

Motadikela

 

 

2 REPLIES 2
Kenda
16 - Nebula
16 - Nebula

Hey @motadikela!

 

I would try adding a Multi-Row Formula tool to create a new field that just contains that section's header like so:

 

motadikela multirow.PNG

 

Then, add a normal Formula tool to concatenate the headers with the following expression for col1:

 

iif(Contains([col1],"["),[col1],[NewField]+[col1])

 You could then use a Select tool to get rid of that new field you created, but the output I got looks like this:

 

motadikela output.PNG

 

Hope this helps!

motadikela
5 - Atom

Thanks Barnes, Its working as expected.

Labels
Top Solution Authors