Get number of days between two event dates in different program stages

Hello DHIS2 community,

I have a doubt how to get number of days between two event dates in different program stages. For example, d2:daysBetween(programstage1.V{event_date},programstage2.V{event_date}).

Anybody used to have experience on this? please help.

Thanks,

Rady

Hi Rady,

I used a kind of hack for doing that:

I first used a program rule to copy the event_date into a new data
element of the program stage (so, yup, the date is kind of duplicated
in the stage).

However then I could create a program rule variable to fetch this date
I wanted, and compare it with another one.

Hope this could help.

Best,

Edouard

···

2018-04-11 6:39 UTC+02:00, Rady <tryrady@gmail.com>:

Hello DHIS2 community,

I have a doubt how to get number of days between two event dates in
different program stages. For example,
*d2:daysBetween(programstage1.V{event_date},programstage2.V{event_date})*.

Anybody used to have experience on this? please help.

Thanks,
Rady

--
*Edouard Lavaud, *

*MSc in Health Policy, Planning & FinancingMEng in
TelecommunicationUniversity Diploma in ICT for Health*
*Email:* edouard.lavaud@gmail.com
*Mobile:* 0033 6 7210 23 59

Hello Edouard,

Many thanks for your guidance. It works fine to me.

Best,

Rady

···

On Wed, Apr 11, 2018 at 1:54 PM, Edouard Lavaud edouard.lavaud@gmail.com wrote:

Anybody used to have experience on this? please help.

Thanks,

Rady

Hi Rady,

I used a kind of hack for doing that:

I first used a program rule to copy the event_date into a new data

element of the program stage (so, yup, the date is kind of duplicated

in the stage).

However then I could create a program rule variable to fetch this date

I wanted, and compare it with another one.

Hope this could help.

Best,

Edouard

2018-04-11 6:39 UTC+02:00, Rady tryrady@gmail.com:

Hello DHIS2 community,

I have a doubt how to get number of days between two event dates in

different program stages. For example,

d2:daysBetween(programstage1.V{event_date},programstage2.V{event_date}).

*Edouard Lavaud, *

*MSc in Health Policy, Planning & FinancingMEng in

TelecommunicationUniversity Diploma in ICT for Health*

Email: edouard.lavaud@gmail.com

Mobile: 0033 6 7210 23 59

Hello friends!.
Is there a solution for 2.25 version?.

Thank you very much.

Regards.

···

2018-04-11 1:54 GMT-05:00 Edouard Lavaud edouard.lavaud@gmail.com:

Hi Rady,

I used a kind of hack for doing that:

I first used a program rule to copy the event_date into a new data

element of the program stage (so, yup, the date is kind of duplicated

in the stage).

However then I could create a program rule variable to fetch this date

I wanted, and compare it with another one.

Hope this could help.

Best,

Edouard

2018-04-11 6:39 UTC+02:00, Rady tryrady@gmail.com:

Hello DHIS2 community,

I have a doubt how to get number of days between two event dates in

different program stages. For example,

d2:daysBetween(programstage1.V{event_date},programstage2.V{event_date}).

Anybody used to have experience on this? please help.

Thanks,

Rady

*Edouard Lavaud, *

*MSc in Health Policy, Planning & FinancingMEng in

TelecommunicationUniversity Diploma in ICT for Health*

Email: edouard.lavaud@gmail.com

Mobile: 0033 6 7210 23 59


Mailing list: https://launchpad.net/~dhis2-devs

Post to : dhis2-devs@lists.launchpad.net

Unsubscribe : https://launchpad.net/~dhis2-devs

More help : https://help.launchpad.net/ListHelp

Cordialmente,

Marko David Garcia M.

Skype: marko_david

Hi

DHIS2 does not currently support V{event_date} for a specific stage - it will always pick the anchor/report date for the most current event.

This is supposed to be fixed in 2.30 - see JIRA issue DHIS2-1397

Regards

Calle

···

On 19 April 2018 at 06:13, Marko David Garcia markodavidgm@gmail.com wrote:

Hello friends!.
Is there a solution for 2.25 version?.

Thank you very much.

Regards.


Mailing list: https://launchpad.net/~dhis2-devs

Post to : dhis2-devs@lists.launchpad.net

Unsubscribe : https://launchpad.net/~dhis2-devs

More help : https://help.launchpad.net/ListHelp

Cordialmente,

Marko David Garcia M.

Skype: marko_david

2018-04-11 1:54 GMT-05:00 Edouard Lavaud edouard.lavaud@gmail.com:

Hi Rady,

I used a kind of hack for doing that:

I first used a program rule to copy the event_date into a new data

element of the program stage (so, yup, the date is kind of duplicated

in the stage).

However then I could create a program rule variable to fetch this date

I wanted, and compare it with another one.

Hope this could help.

Best,

Edouard

2018-04-11 6:39 UTC+02:00, Rady tryrady@gmail.com:

Hello DHIS2 community,

I have a doubt how to get number of days between two event dates in

different program stages. For example,

d2:daysBetween(programstage1.V{event_date},programstage2.V{event_date}).

Anybody used to have experience on this? please help.

Thanks,

Rady

*Edouard Lavaud, *

*MSc in Health Policy, Planning & FinancingMEng in

TelecommunicationUniversity Diploma in ICT for Health*

Email: edouard.lavaud@gmail.com

Mobile: 0033 6 7210 23 59


Mailing list: https://launchpad.net/~dhis2-devs

Post to : dhis2-devs@lists.launchpad.net

Unsubscribe : https://launchpad.net/~dhis2-devs

More help : https://help.launchpad.net/ListHelp


Calle Hedberg

46D Alma Road, 7700 Rosebank, SOUTH AFRICA

Tel/fax (home): +27-21-685-6472

Cell: +27-82-853-5352

Iridium SatPhone: +8816-315-19119

Email: calle.hedberg@gmail.com

Skype: calle_hedberg