1
votes

I have a JasperReports scheduled in Jasper which takes the FromDate and ToDate where FromDate is fixed and I need to pass Today's date as ToDate in Integer format.

Report is running fine when I run manually on JasperReports Server and it is taking today's date as ToDate parameter. Below is the query for parameter which I have written in Jasper while creating parameter:

SELECT date_format( now(), '%Y%m%d') AS today

But when I schedule the report it seems ToDate input control is not passing the Today's date and I always get the date when I scheduled the report as ToDate.

I found few links for the similar issue but still I could not fix, need your help.

Dynamic Date Parameters for Scheduler in JasperServer

1

1 Answers

1
votes

Maybe the following could solve the problem:

SELECT date_format( now(), '%Y-%m-%d') AS today