Customer Portal

Is there a Data Writer equivalent of ComplexDataReader?

Comments 1

  • Avatar
    krizovav
    0
    Comment actions Permalink
    Hi,

    You are right, there is no Writer equivalent to ComplexDataReader. If you need a flat file on the output, you can use FlatFileWriter, but it needs the data to be prepared. It all depends on what data format you are using during the transformation in the graph and what data you are expecting on the output.

    For example, if you need to write the content of a map or a list field, convert the field into string using Reformat first.

    If you are using multiple metadata on multiple edges instead of map or list field, use Reformat for each edge and convert each metadata into one string. Then there are two possibilities how to write this strings into one flat file.
    1. Use SimpleGather for gathering these strings and then use one FlatFileWriter.
    2. Use one FlatFileWriter for each edge, set the “Append” attribute to true and the right Phase for each Writer. Then you can write into one flat file using multiple FlatFileWriters.

    You could also use CustomJavaWriter and set the component behavior by yourself.

    I would also like to bring to your attention the “StructuredDataWriter” component. You can define the structure of your output file using this Writer, but it can be used for a maximum of three inputs. For more information about this component, check the documentation, please.

    I hope this helps.
    Regards,

Please sign in to leave a comment.