Max Value of Date Parameter as Sysdate or Today's date


 I have start date & end date as the input paramter . Enddate  should  be <= to Sysdate or Today's date.

In input control properties , how can enter the Max date as Today's date or sysdate   . Below is scrren shot where i am trying to set the  Max Value.

 Please let me know if we have any work around 

Thanks  in Advance


NColaco's picture
Joined: Jun 29 2012 - 12:13am
Last seen: 10 years 6 months ago

1 Answer:

Unfortunately, this (entering an expression as the minimum/maximum values) is not something that is currently supported within the input controls.  I recommend logging it as an enhancement request in the Tracker.

In the mean time, to acheive nearly the same result, what you could do is allow the future dates but then do a check on the parameter value within the report to see if it is greater than today's date - using a java expression, etc..  If it is greater, then you could use set a variable to today's date and use that in your query and add some text into your report with a printwhen expression that matches the scenario to let the end user know that the report has been run using today's date.

I hope that is helpful.

mgeise's picture
Joined: Mar 5 2007 - 6:18am
Last seen: 3 years 6 months ago
Thanks mgeise. It works.
NColaco - 10 years 7 months ago

It's really a common validation requirement, if FromDate it's after ToDate then it should be a mechanism to tell this to the user at the Input Dialog.

bestia_averno - 7 years 4 months ago

It's really a common validation requirement. But Jasper cannot support this.

598130593 - 7 years 2 months ago
show 1 more...

is this a part of jasper now? if yes how can we achieve this.

vaibhav_jain_ - 5 years 9 months ago