How to create a report variant with dynamic date

Sometimes we want to schedule a report to run daily to update some information in certain tables based on today’s or yesterday’s date or to mail the output of daily MIS reports. We a need a variant to schedule a report, so following are the steps to create a report variant with dynamic date.

First display the selection screen.

dynamic-variant-1

Press save button to create a new variant.

dynamic-variant-2

Enter variant name and description, select the selection variable checkbox and click on Selection variables in the application toolbar.

dynamic-variant-3

Select the option D i.e Dynamic date calculation.

dynamic-variant-4

Once option D is selected, click on the small black triangle to get the F4 values.

dynamic-variant-5

From the list of F4 values select the appropriate value. Here we are creating a variant with yesterday’s date, so we select the second option from the list.

dynamic-variant-6

To get yesterday’s date enter the value  “-1”. Save the variant.