Errors were encountered when compiling report expressions class file:
[jrc] C:\SVN_Current\csk_pos\report.temp\DailyRefundTransactionReport_1184315449517_40192.java:277: operator <= cannot be applied to java.math.BigDecimal,java.math.BigDecimal
[jrc] value = (java.lang.String)(((((java.lang.String)field_refundTransactionTenderType.getValue()).equals("HOME_OFFICE_CHECK")|| ((java.lang.String)field_refundTransactionTenderType.getValue()).equals("CHECK") || ((java.lang.String)field_refundTransactionTenderType.getValue()).equals("CURRENCY")|| ((java.lang.String)field_refundTransactionTenderType.getValue()).equals("TRAVELERS_CHECK")) && (((java.math.BigDecimal)field_refundTransactionAmount.getValue()) <= ((java.math.BigDecimal)field_refundTransactionItemAmount.getValue())))
[jrc] ^
[jrc] C:\SVN_Current\csk_pos\report.temp\DailyRefundTransactionReport_1184315449517_40192.java:285: operator > cannot be applied to java.math.BigDecimal,java.math.BigDecimal
[jrc] : (((java.lang.String)field_refundTransactionTenderType.getValue()).equals("COUPON")|| (((java.math.BigDecimal)field_refundTransactionAmount.getValue()) > ((java.math.BigDecimal)field_refundTransactionItemAmount.getValue())))
[jrc] ^
[jrc] C:\SVN_Current\csk_pos\report.temp\DailyRefundTransactionReport_1184315449517_40192.java:655: operator <= cannot be applied to java.math.BigDecimal,java.math.BigDecimal
[jrc] value = (java.lang.String)(((((java.lang.String)field_refundTransactionTenderType.getOldValue()).equals("HOME_OFFICE_CHECK")|| ((java.lang.String)field_refundTransactionTenderType.getOldValue()).equals("CHECK") || ((java.lang.String)field_refundTransactionTenderType.getOldValue()).equals("CURRENCY")|| ((java.lang.String)field_refundTransactionTenderType.getOldValue()).equals("TRAVELERS_CHECK")) && (((java.math.BigDecimal)field_refundTransactionAmount.getOldValue()) <= ((java.math.BigDecimal)field_refundTransactionItemAmount.getOldValue())))
[jrc] ^
[jrc] C:\SVN_Current\csk_pos\report.temp\DailyRefundTransactionReport_1184315449517_40192.java:663: operator > cannot be applied to java.math.BigDecimal,java.math.BigDecimal
[jrc] : (((java.lang.String)field_refundTransactionTenderType.getOldValue()).equals("COUPON")|| (((java.math.BigDecimal)field_refundTransactionAmount.getOldValue()) > ((java.math.BigDecimal)field_refundTransactionItemAmount.getOldValue())))
[jrc] ^
[jrc] C:\SVN_Current\csk_pos\report.temp\DailyRefundTransactionReport_1184315449517_40192.java:1033: operator <= cannot be applied to java.math.BigDecimal,java.math.BigDecimal
[jrc] value = (java.lang.String)(((((java.lang.String)field_refundTransactionTenderType.getValue()).equals("HOME_OFFICE_CHECK")|| ((java.lang.String)field_refundTransactionTenderType.getValue()).equals("CHECK") || ((java.lang.String)field_refundTransactionTenderType.getValue()).equals("CURRENCY")|| ((java.lang.String)field_refundTransactionTenderType.getValue()).equals("TRAVELERS_CHECK")) && (((java.math.BigDecimal)field_refundTransactionAmount.getValue()) <= ((java.math.BigDecimal)field_refundTransactionItemAmount.getValue())))
[jrc] ^
[jrc] C:\SVN_Current\csk_pos\report.temp\DailyRefundTransactionReport_1184315449517_40192.java:1041: operator > cannot be applied to java.math.BigDecimal,java.math.BigDecimal
[jrc] : (((java.lang.String)field_refundTransactionTenderType.getValue()).equals("COUPON")|| (((java.math.BigDecimal)field_refundTransactionAmount.getValue()) > ((java.math.BigDecimal)field_refundTransactionItemAmount.getValue())))
[jrc] ^
[jrc] 6 errors
[jrc] C:\SVN_Current\csk_pos\report.temp\DailyRefundTransactionReport_1184315449517_40192.java:277: operator <= cannot be applied to java.math.BigDecimal,java.math.BigDecimal
[jrc] value = (java.lang.String)(((((java.lang.String)field_refundTransactionTenderType.getValue()).equals("HOME_OFFICE_CHECK")|| ((java.lang.String)field_refundTransactionTenderType.getValue()).equals("CHECK") || ((java.lang.String)field_refundTransactionTenderType.getValue()).equals("CURRENCY")|| ((java.lang.String)field_refundTransactionTenderType.getValue()).equals("TRAVELERS_CHECK")) && (((java.math.BigDecimal)field_refundTransactionAmount.getValue()) <= ((java.math.BigDecimal)field_refundTransactionItemAmount.getValue())))
[jrc] ^
[jrc] C:\SVN_Current\csk_pos\report.temp\DailyRefundTransactionReport_1184315449517_40192.java:285: operator > cannot be applied to java.math.BigDecimal,java.math.BigDecimal
[jrc] : (((java.lang.String)field_refundTransactionTenderType.getValue()).equals("COUPON")|| (((java.math.BigDecimal)field_refundTransactionAmount.getValue()) > ((java.math.BigDecimal)field_refundTransactionItemAmount.getValue())))
[jrc] ^
[jrc] C:\SVN_Current\csk_pos\report.temp\DailyRefundTransactionReport_1184315449517_40192.java:655: operator <= cannot be applied to java.math.BigDecimal,java.math.BigDecimal
[jrc] value = (java.lang.String)(((((java.lang.String)field_refundTransactionTenderType.getOldValue()).equals("HOME_OFFICE_CHECK")|| ((java.lang.String)field_refundTransactionTenderType.getOldValue()).equals("CHECK") || ((java.lang.String)field_refundTransactionTenderType.getOldValue()).equals("CURRENCY")|| ((java.lang.String)field_refundTransactionTenderType.getOldValue()).equals("TRAVELERS_CHECK")) && (((java.math.BigDecimal)field_refundTransactionAmount.getOldValue()) <= ((java.math.BigDecimal)field_refundTransactionItemAmount.getOldValue())))
[jrc] ^
[jrc] C:\SVN_Current\csk_pos\report.temp\DailyRefundTransactionReport_1184315449517_40192.java:663: operator > cannot be applied to java.math.BigDecimal,java.math.BigDecimal
[jrc] : (((java.lang.String)field_refundTransactionTenderType.getOldValue()).equals("COUPON")|| (((java.math.BigDecimal)field_refundTransactionAmount.getOldValue()) > ((java.math.BigDecimal)field_refundTransactionItemAmount.getOldValue())))
[jrc] ^
[jrc] C:\SVN_Current\csk_pos\report.temp\DailyRefundTransactionReport_1184315449517_40192.java:1033: operator <= cannot be applied to java.math.BigDecimal,java.math.BigDecimal
[jrc] value = (java.lang.String)(((((java.lang.String)field_refundTransactionTenderType.getValue()).equals("HOME_OFFICE_CHECK")|| ((java.lang.String)field_refundTransactionTenderType.getValue()).equals("CHECK") || ((java.lang.String)field_refundTransactionTenderType.getValue()).equals("CURRENCY")|| ((java.lang.String)field_refundTransactionTenderType.getValue()).equals("TRAVELERS_CHECK")) && (((java.math.BigDecimal)field_refundTransactionAmount.getValue()) <= ((java.math.BigDecimal)field_refundTransactionItemAmount.getValue())))
[jrc] ^
[jrc] C:\SVN_Current\csk_pos\report.temp\DailyRefundTransactionReport_1184315449517_40192.java:1041: operator > cannot be applied to java.math.BigDecimal,java.math.BigDecimal
[jrc] : (((java.lang.String)field_refundTransactionTenderType.getValue()).equals("COUPON")|| (((java.math.BigDecimal)field_refundTransactionAmount.getValue()) > ((java.math.BigDecimal)field_refundTransactionItemAmount.getValue())))
[jrc] ^
[jrc] 6 errors
1 Answer:
Posted on July 13, 2007 at 12:43pm
You should cast $F{refundTrasactionAmount} AND $F{refund_TransactionItemAmount} to an 'int' Or a 'double' before applying the .equals() method to them...
Try this:
Try this:
Code: |
<br /> ... && $F{refund_TransactionItemAmount}.intValue()<br /> <br /> && Integer.parseInt($F{refund_TransactionItemAmount})<br /> </td></tr></tbody></table><br /> <br /> Or something like it. Research the conversion methods used in java, that is what your problem is. |