Pentaho 5.3 - How to read a property in PRPT files

半城伤御伤魂 提交于 2019-12-12 06:37:32

问题


I need to set a value in a properties file and then read this value in a PRPT in Pentaho 5.3.If I understand it, the file where to add my property is design-tools/report-designer/resources/classic-engine.properties (Report Designer) and server/biserver-ee/tomcat/webapps/pentaho/WEB-INF/classes/classic-engine.properties (BI server, once published).That's right? If so, could you tell me how I can read this value (example, pentaho.images.path=c:/myProject/images/) in my PRPT file? If not, could you explain to me how to do? Thank you!


回答1:


I found a solution... I write it if that can be useful to someone. Files listed in question are correct. We need write in classic-engine.properties:

org.pentaho.reporting.engine.classic.core.environment.pentahoImgPath=c:/myProject/images/
org.pentaho.reporting.engine.classic.core.env-mapping.pentahoImgPath=env\:\:pentahoImgPath

Restart the Report Designer. Now, we have a new environment variable in PRPT file once opened with the Report Designer, env::pentahoImgPath The value is contained in "org.pentaho.reporting.engine.classic.core.environment.pentahoImgPath" key (c:/myProject/images/). Bye.

Andrea



来源:https://stackoverflow.com/questions/30781862/pentaho-5-3-how-to-read-a-property-in-prpt-files

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