Hitachi Vantara Pentaho Community Forums
Results 1 to 2 of 2

Thread: Run different transformation depending on file contents

  1. #1

    Default Run different transformation depending on file contents

    Hi guys,

    I've crafted 3 different tranformations that run on the same file. They replace some old excel code that sucked and didn't work properly. Now they do work properly but my boss liked the old functionality where by a different bit of code runs when the file has one of 3 different unix screen dumps in it.

    Its a right pain in the ass but is it possible to have for example a master job that can examine the file and if a certain line matches a certain string then it will call one transformation, if it matches a different string it will run a second transformation etc. The file structure is always the same with the headings just the figures are different so if I could pattern match a heading i guess it might work.

    At the moment there's the 3 different jobs sat there but he's too lazy to sort out which one to run, and it would just make for some cleaner functionality.

    Cheers

    Tom

  2. #2
    Join Date
    Nov 1999
    Posts
    9,729

    Default

    Should be very possible.
    You need to set a variable in a job before you hit the Transformation job entry where you specify the transformation to run with said variable.
    You can create a transformation to set the variable.
    With a couple of filters or maybe a bit of Javascript to determine the transformation to run, etc.

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.