Skip to main content
Question

FME - CSV writer - why can i only see vchar as a field datatype, when i need char?

  • November 24, 2023
  • 1 reply
  • 9 views

matt_ccc
Contributor
Forum|alt.badge.img+2

Looking to create a csv output as a 'dat' file for import to another system. basically rows of text with the fields essentially defined by the number of characters they occupy in the row, padded as necessary. So, i need the output row length to be fixed for each field, and yet I only have the otpion of vchar.

In online documentation I can see reference to a datatype of char, but this is not exposed in the fme writer.

Why is it missing? / Why have I missed it?

Help appreciated.

Using FME Desktop 2022.1.2.0

1 reply

takashi
Influencer
  • November 24, 2023

Hi @matt_ccc​ ,

If you intend to create a column aligned (column width fixed) text format dataset, I don't think using CSV writer is the best way.

I would recommend you to firstly make each column text appropriate width with StringPadder(s), concatenates all of them into a single string with StringCocnatenator etc., then write the concatenated string into a 'dat' file with Text File writer or Data File writer.

Hope this helps.


Reply


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings