How to add $ symbol to the value field in the pentaho report designer

孤人 提交于 2019-12-12 00:47:43

问题


I have field which is taking string as datatype and that field has values like $20000 and N/A. I am using the string as datatype I want to show data like this $20000 and N/A, but I am getting it as a 20000 and N/A. How can I get data as $20000 and N/A. I am using that expression:

=IF([annual_roll_amount]=="N/A";"N/A";"$" &[annual_roll_amount])

What is wrong in this expression and Is it ok to use that in value field under attributes??


回答1:


Your expression is wrong. you have to use CONCATENATION.

=IF([annual_roll_amount]=="N/A";"N/A";CONCATENATE("$";[annual_roll_amount]))


来源:https://stackoverflow.com/questions/51527899/how-to-add-symbol-to-the-value-field-in-the-pentaho-report-designer

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