Jump to content
We've recently updated our Privacy Statement, available here ×
  • Dynamic Financial Quarter filter in Ireports


    yananderson
    • Product: iReport Designer

    Hi,

    I found a need to do this and no resources on how to do it so having done the leg work here it is incase anyone wants to:

    Dynamicly filter a report based on results running from the beginning of the current quarter up to the current date:

    Create a date between filter then change the parameters to the following defaults:

     

    ((new Date().getMonth()) >= 0 && (new Date().getMonth()) <=  2 ? new Date((new Date().getYear()), 0, 1) :</div><div>(new Date().getMonth()) >= 3 && (new Date().getMonth()) <=  5 ? new Date((new Date().getYear()), 3, 1) :</div><div>(new Date().getMonth()) >= 6 && (new Date().getMonth()) <=  8 ? new Date((new Date().getYear()), 6, 1) :  new Date((new Date().getYear()), 9, 1))
    new java.util.GregorianCalendar().getTime()

    User Feedback

    Recommended Comments

    There are no comments to display.



    Guest
    This is now closed for further comments

×
×
  • Create New...