Your achievements

Level 1

0% to

Level 2

Tip /
Sign in

Sign in to Community

to gain points, level up, and earn exciting badges like the new
BedrockMission!

Learn more

View all

Sign in to view all badges

SOLVED

Can I generate a .txt file with fixed width columns and column headers?

JonasLundstrom8
Level 1
Level 1

Hello,

 

I am currently importing and reconciling a .txt file from an external source, after processing, part of the content needs to be exported again.

My problem stems from the formatting, the file needs to adhere to the same format as the imported file. Which is not a problem using 1219536_pastedImage_0.png

However when I use the above settings I lose the column headers. I have tried to modify the xml-source:

1219537_pastedImage_2.png

saveTitle according to documentation is the attribute that declares the column header, however the format attribute:"fixed" seems to override any such tampering.

Using the basic Text export which allows you to select via checkbox first line as column header is not looking like a viable option since the columns are of various widths without a uniform separator and modifying the incoming file is not possible. Any tips to work around this? I was looking into creating a file via a javascript activity in some sort of filestream but have not found anything that works.

 

Thanks for you time.

/Jonas L

1 Accepted Solution
florentlb
Correct answer by
Level 10
Level 10

Hi Jonas,

Just got confirmation that the product team is aware of the improvement possibilities for this option but it seems that there is no known workaround at the moment to directly add a header to the file.

I'll keep you updated with it but as this option is not used a lot it could take several months.

Let me know if you have other questions.

Florent.

View solution in original post

3 Replies
florentlb
Level 10
Level 10

Hi Jonas,

Indeed there seems to be no header options with this mode. I'm trying to get some feedback to see if this is a common practice and if there are possible workarounds.

Florent.

florentlb
Correct answer by
Level 10
Level 10

Hi Jonas,

Just got confirmation that the product team is aware of the improvement possibilities for this option but it seems that there is no known workaround at the moment to directly add a header to the file.

I'll keep you updated with it but as this option is not used a lot it could take several months.

Let me know if you have other questions.

Florent.

View solution in original post

vasudevaraog731
Level 3
Level 3

Hi,

We have tried the below option in data extraction activity by checking "Use first line as column header" but when the "zero" records coming from previous target it's not generating column header in Target file

Is it a Product feature?

1483797_pastedImage_0.png