Get Due Date from Event Reports

Dear All,
Please, we have a repeatable program stage (follow-up visits) where the due date is dubbed as the ‘next appointment date’
Is there a way to get this next appointment date from the event reports?


Dear @ifeanyiokoye,

It seems that what ever you will be getting from the event reports would be the same as a value that you can use a program indicator or a program rule to get it. I understand that you want the ‘next appointment date’ to be based on a value that you see in the event reports? Would explain further about the use case?

Thank you!

Thanks @Gassim.

So we run several clinics and the follow-up visit data is captured using the tracker. We used the due date to schedule their next appointments and would like to be able to generate the list of patients who have appointments on a certain day from the event reports.

If you could provide more guidance on using a program indicator to store the data in the variable due date, it would be most appreciated.

Thank you.

Hello Community,
I used a program rule to assign the value in V{due_date} to a data element and when I run an event report, I noticed that the date stored against the data element in a majority of the cases is not the current due date but the previous value.
My program rule expression has this d2:hasValue( ‘due_date’ )
and program rule action has Assign value: “V{due_date}” to field “PMM Next Appointment Date”

A number of the records were blank even though the patient had a next appointment date scheduled for a future period.

I have tried using expressions like greatest(V{due_date}) but that did not change anything.

Is this something I am doing wrong or is this an issue from DHIS2? We are running 2.36.8.


Thank you,


Hi @ifeanyiokoye,

Could this be because of when the rule is being triggered? If you are using a tracker program, did you try “Trigger rule only for program stage”?

It does say in the docs:

[due_date] variable will contain the current date when the rule is executed. Note: This means that the rule might produce different results at different times, even if nothing else has changed.