Skip to main content
Question

Read FTP file into attribute and create list

  • June 24, 2019
  • 2 replies
  • 51 views

dbryantgeo
Contributor
Forum|alt.badge.img+7

I have a predicament where I need to read a .txt file containing a list of reference numbers (example attached) .

The file is dropped by a supplier onto our SFTP.

The file usually contains customer information and therefore I don't want to store that file in a different format (e.g. csv) and read from it.

I figured that I could just use the ListBuilder to create a List from the Attribute that the file contents is stored in. However, this does not appear to work - I'm still getting a single attribute value containing the contents in the inspector.

Can anybody think of anything or am I just going to have to temporarily store, re-read and then delete the file?

This post is closed to further activity.
It may be an old question, an answered question, an implemented idea, or a notification-only post.
Please check post dates before relying on any information in a question or answer.
For follow-up or related questions, please post a new question or idea.
If there is a genuine update to be made, please contact us and request that the post is reopened.

2 replies

ebygomm
Influencer
Forum|alt.badge.img+44
  • Influencer
  • 3427 replies
  • June 24, 2019

If you're reading the entire text file into a single attribute you want to use an attributesplitter to split on the linebreak to create your list


palhermans
Contributor
Forum|alt.badge.img+10
  • Contributor
  • 46 replies
  • June 24, 2019

Hi. You are fine to read the txt file with the CSV reader and reference the location at the FTP. Authentification must of course be included in the reader

  • Source CSV: ftp://________/yourtextfile.txt
  • field names Line: 1
  • data start line: 2