Solved

How to reference CSV from Writer for S3Connector?

  • 23 March 2022
  • 2 replies
  • 3 views

Badge +1

How can I reference the CSV created from a Writer to upload to AWS S3 using S3Connector? I can successfully use a Reader to reference a file on my computer and upload to AWS S3 using my Web Connection and S3Connector, but I don't know how to reference a newly created file within my worflow. See attached.

icon

Best answer by chrisatsafe 23 March 2022, 16:52

View original

2 replies

Badge +2

Hi @osdev​ ,

You'll likely want to use a FeatureWriter instead. The FeatureWriter is essentially the transformer version of a writer which allows you to continue processing after a file has been created. If you replace your CSV writer with a FeatureWriter, you can simply connect the summary port to the S3Connector and use the summary attribute _dataset to set the file to upload (i.e. @Value(_dataset)\\<filename>.csv).

imageIf you want to only create a temporary csv you can also mix in a TempPathnameCreator.

 

Badge +1

The FeatureWriter transformer worked great! Thank you.

Reply