In pentaho..How to pass a text file which contains all the definition of the connection parameters in the job?

偶尔善良 提交于 2019-12-08 06:22:39

问题


I am using jdbc connection and i am passing parameters with example ${sample_db_connection} and that parameters has been defined in server in a text file as sample_db_connection=localhost and i want to pass the text file in the job step so that whenever the job ran and it found this parameter ,automatically it will take the value defined in text file.


回答1:


You need to create a KTR file using "Property Input" as the input step and "Modified Java Script" Step to define the key value mapping. Check the image below:

Define your filename in the input step. In the JS step, you can use "setVariable" function to define the key-value mapping.

Once this job is executed at the start, pentaho will set the variables for all the connection.

Hope i have understood the question correctly and this is what you are looking for !! :)



来源:https://stackoverflow.com/questions/27522140/in-pentaho-how-to-pass-a-text-file-which-contains-all-the-definition-of-the-con

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!