Hitachi Vantara Pentaho Community Forums
Results 1 to 3 of 3

Thread: XML filename from field in stream

  1. #1
    Join Date
    Apr 2008
    Posts
    20

    Default XML filename from field in stream

    Hi,

    I am working on a transformation where I output fileds to a XML file.... I just want one of the fields to be used for filename... I have tried with setting a variable.. but no luck.. any ideas?

  2. #2
    Join Date
    May 2006
    Posts
    4,882

    Default

    You can't set a variable in the same transformation as where you use it. It takes a few workarounds: you'd first have to set the output name as a variable, and then somehow collect all records to be written to it, repeating this for all different names in the input.

    In the PDI installation under "samples\job\process all tables" you have something similar but for inputs.

    Regards,
    Sven
    Last edited by sboden; 06-09-2008 at 09:20 AM.

  3. #3
    DEinspanjer Guest

    Default

    I'd suggest filing a Jira enhancement request for this functionality.

    If you know Java, you could even look at implementing it yourself. The XML output step and the Text file output step are fairly similar and in PDI 3.1 a feature has been added to the Text file output step to accept the filename based on a field. That feature could probably be ported over to the XML output step without too much trouble.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Privacy Policy | Legal Notices | Safe Harbor Privacy Policy

Copyright © 2005 - 2019 Hitachi Vantara Corporation. All Rights Reserved.