Data360 Analyze

 View Only
  • 1.  Create Global Custom Function

    Employee
    Posted 10-14-2019 06:50

    How can I create a global custom function(python), which can be used anywhere in the job. Right now, I am creating function in every component I need.



  • 2.  RE: Create Global Custom Function

    Employee
    Posted 10-14-2019 08:34

    Note: This was originally posted by an inactive account. Content was preserved by moving under an admin account.

    I can think of a couple of ways to at least help you out, but it's not exactly what you're asking.

     

    1. Create a library node with the function in it and just use this where needed.
    2. This is a little messy but if you don't want to create too many library nodes you could create a Data Flow Parameter of type text (let's say name it PyFunction) and enter your function there. Then when you start a new Transform node in ConfigureFields you just need to put in {{^PyFunction^}} and it will be the equivalent of copying and pasting it to every Transform node.