Pass DB Connection parameters to a Kettle a.k.a PDI table Input step dynamically from Excel -
I have a requirement whenever I run my own kettle, dynamically took database connection parameters from an excel source Every run should go.
I have an Excel column names: hostname, username, database, password.
I want to pass these connection parameters to my table input stage dynamically whenever it runs the job.
This is what I was trying to do.
You can get it
- Connection parameters from the DB reading source (for example Excel or a CSV file in my example) < / Li>
- Store the parameters in the variable
- Using the variable in your connection's settings.
- Setting Variables Create another conversion for (you can not do it in the same conversion Uses):
- The element that reads / writes your data creates a new connection and sets the connection parameter using
$ {variable name_}
Note that you will need to type in the field field in the field$ {password}
Also keep in mind that this can be a security problem as the price can be shown as plain text in log files!
- < Li> Make a variable change in your job first and then call functional part:
Comments
Post a Comment