Clarity

  • 1.  Jaspersoft:  Exception getting data strategy; does not exist

    Posted Aug 30, 2017 04:20 PM

    Getting odd errors when saving/running Jaspersoft ad hoc report.  Why odd?  Well, the ad hoc view works perfect - only when I try to save/run as a report do I get these errors:

     

    - java.lang.illegalArguementException: resource id:  RiskScore_1 does not exist

    - exception getting data strategy

     

    Google search and search of Jaspersoft site produced no applicable results.

     

    Both errors are related to filters, which are based on calculated fields:

     

    • Calculated Risk Score is not available for export to DWH (unchecked box shaded out/not editable on attribute in Risk Object)
    • So, I use Risk Impact and Risk Probability in Jaspersoft to calculate the Risk Score
      • Create Risk Probability Number (RPN) and Risk Impact Number (RIN) fields using CASEWHEN function to convert Low, Medium, High to 1, 2, 3
      • Create a Risk Score Number field which is the calculated value (multiple) of RPN and RIN
      • Create a Risk Score field using CASEWHEN to convert numeric result back into readable Low, Medium, High text
    • In the column section of ad hoc view, I place Risk Score - users can read the Low, Medium, High values
    • All good
    • I then create Risk Score as a filter
      • Set filter to "High"
      • Apply - get expected results to display
      • Save ad hoc view
      • All good
    • Then, create Report from ad hoc view
      • Expect report to save
      • Instead, get error message:  java.lang.illegalArguementException: resource id:  RiskScore_1 does not exist
    • Next,
      • remove Risk Score as filter from ad hoc view
      • Create filter from Risk Score Number
      • Set filter to ">=6"
      • Apply - get expected results to display
      • Save ad hoc view
      • All good
    • Then, create Report from ad hoc view
      • Expect Report to save
      • Instead get error message:  exception getting data strategy
      • (BTW - fed up with the "Please excuse the inconvenience" message in the error window...c'mon, give me something useful, please.")
    • Next, remove Risk Score filter from ad hoc view
      • no filters of any kind left related risk score, impact, probably, whether numbers or text
      • Save ad hoc view
      • All good
    • Then, create Report from ad hoc view
      • Expect Report to save
      • It does
      • Report runs
      • Would be fine, but I can't filter for the "High"/">=6" risks.

     

    Any ideas?

     

    Odd that these filters work fine in ad hoc view, but then report says field doesn't exist or can't get a 'strategy' - maybe there's an error but these are the wrong messages?

     

    Open to any ideas.

     

    Dale



  • 2.  Re: Jaspersoft:  Exception getting data strategy; does not exist

    Broadcom Employee
    Posted Aug 30, 2017 11:16 PM

    Hi Dale,

     

    Can you please let me know what domain you are using and it looks like while creation its erroring out, which makes me think that a problem with the attribute but there are certain traces in Jaspersoft pertaining to Adhoc view and Domain and from there you can pin point the problem.

     

    Regards

    Suman Pramanik  



  • 3.  Re: Jaspersoft:  Exception getting data strategy; does not exist

    Posted Aug 31, 2017 08:59 AM

    Hi Suman.   I’m using the Project Domain.



  • 4.  Re: Jaspersoft:  Exception getting data strategy; does not exist

    Broadcom Employee
    Posted Sep 01, 2017 03:13 AM

    Hi Dale,

     

    It looks like there is some corruption with the domain and we might need to resyn the domain and see if that works

     

    admin content-jaspersoft csk restoreDomains -userName superuser –password superuser  

     

    Regards

    Suman Pramanik



  • 5.  Re: Jaspersoft:  Exception getting data strategy; does not exist

    Posted Sep 06, 2017 03:12 PM

    Suman - ad-hoc view and report run fine without the fields I created in the view used as filters.  These created fields aren't part of the domain, correct?  What would be the corruption in the domain that might cause this, then?  And, why does it work in the view, but not the report? 

     

    In meantime, I've come up with a solution, by simplifying my ad-hoc filtering, which must simplify the resulting query.

     

    Rather than converting Impact and Probability to numbers using two fields, multiplying the two fields in a third field and using this third field as a filter, I just do it all in one field:

     

    New Risk Score = CASE("Risk Probability", 'High', 3, "Risk Probability", 2, 3) * Case("Risk Impact", 'High', 3, "Risk Probability", 2, 3)

     

    Then filter on >=6.

     

    Must be simpler.  Works both in ad-hoc view and in report.  Happy-happy!

     

    In final version of report, would like to convert numeric "New Risk Score" back to text so that users can pick from simpler "High, Medium, Low" value list rather than remembering the numeric thresholds corresponding to each text value.  Will try wrapping above formula in another CASE statement in order to keep it all in one field. 

     

    But this is good enough for now.  

     

    Thanks for the feedback - helps get ideas flowing.

     

    Dale



  • 6.  Re: Jaspersoft:  Exception getting data strategy; does not exist

    Posted Sep 11, 2017 08:20 AM

    Hi Dale,


    are you on demand? If not, please have a look at the Jaspersoft logfiles, as the UI error messages are meaningless on purpose for security reasons.


    Generally, I would like to remark that whereas adhoc views can handle empty result sets, the adhoc report will throw an error if no data is found.

     

    I hope I could help

     

    Best regards
    Georg



  • 7.  Re: Jaspersoft:  Exception getting data strategy; does not exist

    Posted Jan 04, 2019 02:49 AM

    Hi All,

     

    for us it was an object attribute, that was unflagged from being synched to the DWH,

    thus the error "exception getting data strategy" occured.

     

    The jaspersoft.log made the cause obvious, after flagging and loading the DWH the reports worked again.

     

    HTH.

     

    Best regards,

    Sebastian