Jump to content
We've recently updated our Privacy Statement, available here ×

maria.pereira

Members
  • Posts

    3
  • Joined

  • Last visited

maria.pereira's Achievements

Rookie

Rookie (2/14)

  • Week One Done
  • One Month Later
  • One Year In
  • First Post Rare
  • Conversation Starter Rare

Recent Badges

0

Reputation

  1. I`m doing a report and I have to print all of the data starting from a given value, passed as parameter. For example, I want print a relation of all of products that the availability is at least x, that is, I will print the products that have stock f x and x+. My related parameter and field are BigDecimal, I didn`t get trying this way: ($P{cenaOd} != null ?$F{lacznyStan}.equals($P{cenaOd}): true ) It appears the following error: java.lang.ClassCastException: java.lang.Integer cannot be cast to java.math.BigDecimal Can someone help me?
  2. I`m doing a report and I want that this report can filter the generated documents for many factors, as data, payment, type, etc. For that I use filter expression, but I want that in the report show up the filter used, and there is one these factors that is not working, the parameter of class java.util.List. I want that just appear if the filter was used, otherwise it does not seem anything. In my report is print just the sentence before the variable that should be print. The filter used: ($P{docNo} != null ? $F{numer}.equals($P{docNo}) : true ) && ($P{warehouse} != null ? $F{symbol}.equals($P{warehouse}): true) && ($P{kthNo} != null ? $F{idKth}.equals(Integer.parseInt($P{kthNo})) : true ) && ($P{tdokList} != null ?$P{tdokList}.contains($F{typ}): true ) && ($P{dateFrom} != null ? $F{dataDok}.after(new java.sql.Date($P{dateFrom})) : true ) && ($P{dateTo} != null ? $F{datawe}.before(new java.sql.Date($P{dateTo} )): true) && (($P{unsettled} != null && $P{unsettled}) ? ( $F{settledPosCount}!=$F{posCount} ) : true ) && (($P{settled} != null && $P{settled} )? ( $F{settledPosCount}==$F{posCount} ) : true) And the expression used for the other parameters: (($P{dateFrom}.equals(""))&&($P{dateTo}.equals("")))?"":("nData od: "+(new SimpleDateFormat("dd-MM-yyyy").format($P{dateFrom}))+ " do: "+(new SimpleDateFormat("dd-MM-yyyy").format($P{dateTo})))+(($P{docNo} != null && !$P{docNo}.isEmpty())?("nNr dok.: "+$P{docNo}):"")+(($P{warehouse} != null && !$P{warehouse}.isEmpty())?("nMagazyn: "+$P{warehouse}):"")+(($P{kthNo} != null && !$P{kthNo}.isEmpty())?("Nr Kth.: "+$P{kthNo}):"")+("nRozliczone: "+($P{settled}?"tak":""))+("nNie rozliczone: "+($P{unsettled}?"tak":"")) For the parameter of list type I`m using: (($P{tdokList} != null && !$P{tdokList}.isEmpty())?("Typ dokumentu: "+$P{tdokList}):"") and it`s not working. Anyone know how I can fix this?
  3. I`m trying to do a report on JasperSoft Studio using filter expression, I have to do a report where it is possible to filter the documents generated by type, number, date and situation of the application (paied, settled and unsettled). I`ve already done for the firsts parameters and now i have to do for the situation of the application, but i dont know how to do this, because i have multiples selects from differents tables without combination. The code that is working for the firsts parameters: select d.tdok typ, d.nr numer, d.symbmg symbol, d.data dataDok, d.dokumwe dokumWe, d.datawe datawe, d.idkntrh idKth, d.kwotadok kwotadok, d.kwotavat, k.nazwa1 nazwa1, k.nazwa2 nazwa2 from dokum0 d join kontrahent0 k on d.idkntrh=k.idkntrh And the nexts selects are: select t.kwota_n kwota_n from dokumterm t where t.dokum_id = id_dokum; select p.id_pozdok0 AS settledCount from pozdok p where p.dokum_id = id_dokum; select p.id_pozdok0 AS posCount from pozdok p where p.dokum_id=id_dokum; select t.kupspr kupspr from sltdok t where t.tdok=tdok; And I have to organize by: The document is settled if settledPosCount is equal a posCount, and it is unsettled if settledPosCount is not equal a posCount and kupspr is equal a 0. Anyone can help me?
×
×
  • Create New...