using report date in the program rule

Hello,
Best wishes for 2018.

I am trying to do the following in an event-capture program:

  • capture the year of the event date (report date) and assign it to a
    program rule variable.

I will be thankful if you can assist me.
Sincerely
NG

···

Nada Ghosn, MD

Head, Epidemiology Surveillance Program (Esumoh)

Ministry of Public Health

Beirut, Museum square

Lebanon

Tel +961.1.614194

Fax +961.1.610920

Email esumohleb@gmail.com, esumoh@moph.gov.lb

Website www.moph.gov.lb

Hi Nada,

Best wishes for 2018 !

Regarding your query I assume the problem you are facing with is how to obtain the year from the event date. Considering the date format you can get the string value of the year by obtaining the first 4 digits from the left side of the value for the event date. So I suggest you use the following function.

d2:left(V{event_date}, 4)

Hope this helps.

···

On Mon, Jan 1, 2018 at 9:35 PM, Nada Ghosn esumohleb@gmail.com wrote:

Nada Ghosn, MD

Head, Epidemiology Surveillance Program (Esumoh)

Ministry of Public Health

Beirut, Museum square

Lebanon

Tel +961.1.614194

Fax +961.1.610920

Email esumohleb@gmail.com, esumoh@moph.gov.lb

Website www.moph.gov.lb

Hello,
Best wishes for 2018.

I am trying to do the following in an event-capture program:

  • capture the year of the event date (report date) and assign it to a
    program rule variable.

I will be thankful if you can assist me.
Sincerely
NG


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

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

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

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

Regards,
Dr. Pamod Amarakoon

MBBS (SL)

MSc (Biomedical Informatics), EMSc (Health Admin), PGCert (MedEd), CEH

Medical Officer in Health Informatics

Nutrition Coordination Division

Ministry of Health, Nutrition and Indigenous Medicine,

Sri Lanka

Confidentiality Notice: the information contained in this email and any attachments may be legally privileged and confidential. If you are not an intended recipient, you are hereby notified that any dissemination, distribution, or copying of this e-mail is strictly prohibited. If you have received this e-mail in error, please notify the sender and permanently delete the e-mail and any attachments immediately. You should not retain, copy or use this e-mail or any attachments for any purpose, nor disclose all or any part of the contents to any other person.

Good evening,
Thank you for your prompt reply.

I did the expression and it works.

However, i have to click on the field (year) to get the value.

I will be thankful if you can advise on how to get the value automatically without having to click in the target field (year)

Sincerely

NG

···

On Mon, Jan 1, 2018 at 8:19 PM, Pamod Amarakoon pamodm@gmail.com wrote:

Hi Nada,

Best wishes for 2018 !

Regarding your query I assume the problem you are facing with is how to obtain the year from the event date. Considering the date format you can get the string value of the year by obtaining the first 4 digits from the left side of the value for the event date. So I suggest you use the following function.

d2:left(V{event_date}, 4)

Hope this helps.

On Mon, Jan 1, 2018 at 9:35 PM, Nada Ghosn esumohleb@gmail.com wrote:

Nada Ghosn, MD

Head, Epidemiology Surveillance Program (Esumoh)

Ministry of Public Health

Beirut, Museum square

Lebanon

Tel +961.1.614194

Fax +961.1.610920

Email esumohleb@gmail.com, esumoh@moph.gov.lb

Website www.moph.gov.lb

Hello,
Best wishes for 2018.

I am trying to do the following in an event-capture program:

  • capture the year of the event date (report date) and assign it to a
    program rule variable.

I will be thankful if you can assist me.
Sincerely
NG


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

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

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

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

Regards,
Dr. Pamod Amarakoon

MBBS (SL)

MSc (Biomedical Informatics), EMSc (Health Admin), PGCert (MedEd), CEH

Medical Officer in Health Informatics

Nutrition Coordination Division

Ministry of Health, Nutrition and Indigenous Medicine,

Sri Lanka

Confidentiality Notice: the information contained in this email and any attachments may be legally privileged and confidential. If you are not an intended recipient, you are hereby notified that any dissemination, distribution, or copying of this e-mail is strictly prohibited. If you have received this e-mail in error, please notify the sender and permanently delete the e-mail and any attachments immediately. You should not retain, copy or use this e-mail or any attachments for any purpose, nor disclose all or any part of the contents to any other person.

Nada Ghosn, MD

Head, Epidemiology Surveillance Program (Esumoh)

Ministry of Public Health

Beirut, Museum square

Lebanon

Tel +961.1.614194

Fax +961.1.610920

Email esumohleb@gmail.com, esumoh@moph.gov.lb

Website www.moph.gov.lb

Hi Nada,

It should come automatically if you already have a data element for the age field and if you have applied a rule to assign the value of the expression above to the data element.

···

On Mon, Jan 1, 2018 at 11:17 PM, Nada Ghosn esumohleb@gmail.com wrote:

Good evening,
Thank you for your prompt reply.

I did the expression and it works.

However, i have to click on the field (year) to get the value.

I will be thankful if you can advise on how to get the value automatically without having to click in the target field (year)

Sincerely

NG

On Mon, Jan 1, 2018 at 8:19 PM, Pamod Amarakoon pamodm@gmail.com wrote:

Hi Nada,

Best wishes for 2018 !

Regarding your query I assume the problem you are facing with is how to obtain the year from the event date. Considering the date format you can get the string value of the year by obtaining the first 4 digits from the left side of the value for the event date. So I suggest you use the following function.

d2:left(V{event_date}, 4)

Hope this helps.


Nada Ghosn, MD

Head, Epidemiology Surveillance Program (Esumoh)

Ministry of Public Health

Beirut, Museum square

Lebanon

Tel +961.1.614194

Fax +961.1.610920

Email esumohleb@gmail.com, esumoh@moph.gov.lb

Website www.moph.gov.lb

On Mon, Jan 1, 2018 at 9:35 PM, Nada Ghosn esumohleb@gmail.com wrote:

Nada Ghosn, MD

Head, Epidemiology Surveillance Program (Esumoh)

Ministry of Public Health

Beirut, Museum square

Lebanon

Tel +961.1.614194

Fax +961.1.610920

Email esumohleb@gmail.com, esumoh@moph.gov.lb

Website www.moph.gov.lb

Hello,
Best wishes for 2018.

I am trying to do the following in an event-capture program:

  • capture the year of the event date (report date) and assign it to a
    program rule variable.

I will be thankful if you can assist me.
Sincerely
NG


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

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

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

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

Regards,
Dr. Pamod Amarakoon

MBBS (SL)

MSc (Biomedical Informatics), EMSc (Health Admin), PGCert (MedEd), CEH

Medical Officer in Health Informatics

Nutrition Coordination Division

Ministry of Health, Nutrition and Indigenous Medicine,

Sri Lanka

Confidentiality Notice: the information contained in this email and any attachments may be legally privileged and confidential. If you are not an intended recipient, you are hereby notified that any dissemination, distribution, or copying of this e-mail is strictly prohibited. If you have received this e-mail in error, please notify the sender and permanently delete the e-mail and any attachments immediately. You should not retain, copy or use this e-mail or any attachments for any purpose, nor disclose all or any part of the contents to any other person.

Regards,
Dr. Pamod Amarakoon

MBBS (SL)

MSc (Biomedical Informatics), EMSc (Health Admin), PGCert (MedEd), CEH

Medical Officer in Health Informatics

Nutrition Coordination Division

Ministry of Health, Nutrition and Indigenous Medicine,

Sri Lanka

Confidentiality Notice: the information contained in this email and any attachments may be legally privileged and confidential. If you are not an intended recipient, you are hereby notified that any dissemination, distribution, or copying of this e-mail is strictly prohibited. If you have received this e-mail in error, please notify the sender and permanently delete the e-mail and any attachments immediately. You should not retain, copy or use this e-mail or any attachments for any purpose, nor disclose all or any part of the contents to any other person.

Good evening,
Thank you again for your prompt reply.

I shall test the new program again.

I will be thankful if you can assist me in the following query:

how to create a data element to retain the name of the orgunit.

Sincerely

Nada

···

On Mon, Jan 1, 2018 at 9:15 PM, Pamod Amarakoon pamodm@gmail.com wrote:

Hi Nada,

It should come automatically if you already have a data element for the age field and if you have applied a rule to assign the value of the expression above to the data element.

On Mon, Jan 1, 2018 at 11:17 PM, Nada Ghosn esumohleb@gmail.com wrote:

Good evening,
Thank you for your prompt reply.

I did the expression and it works.

However, i have to click on the field (year) to get the value.

I will be thankful if you can advise on how to get the value automatically without having to click in the target field (year)

Sincerely

NG

Regards,
Dr. Pamod Amarakoon

MBBS (SL)

MSc (Biomedical Informatics), EMSc (Health Admin), PGCert (MedEd), CEH

Medical Officer in Health Informatics

Nutrition Coordination Division

Ministry of Health, Nutrition and Indigenous Medicine,

Sri Lanka

Confidentiality Notice: the information contained in this email and any attachments may be legally privileged and confidential. If you are not an intended recipient, you are hereby notified that any dissemination, distribution, or copying of this e-mail is strictly prohibited. If you have received this e-mail in error, please notify the sender and permanently delete the e-mail and any attachments immediately. You should not retain, copy or use this e-mail or any attachments for any purpose, nor disclose all or any part of the contents to any other person.

On Mon, Jan 1, 2018 at 8:19 PM, Pamod Amarakoon pamodm@gmail.com wrote:

Hi Nada,

Best wishes for 2018 !

Regarding your query I assume the problem you are facing with is how to obtain the year from the event date. Considering the date format you can get the string value of the year by obtaining the first 4 digits from the left side of the value for the event date. So I suggest you use the following function.

d2:left(V{event_date}, 4)

Hope this helps.

Nada Ghosn, MD

Head, Epidemiology Surveillance Program (Esumoh)

Ministry of Public Health

Beirut, Museum square

Lebanon

Tel +961.1.614194

Fax +961.1.610920

Email esumohleb@gmail.com, esumoh@moph.gov.lb

Website www.moph.gov.lb

On Mon, Jan 1, 2018 at 9:35 PM, Nada Ghosn esumohleb@gmail.com wrote:

Nada Ghosn, MD

Head, Epidemiology Surveillance Program (Esumoh)

Ministry of Public Health

Beirut, Museum square

Lebanon

Tel +961.1.614194

Fax +961.1.610920

Email esumohleb@gmail.com, esumoh@moph.gov.lb

Website www.moph.gov.lb

Hello,
Best wishes for 2018.

I am trying to do the following in an event-capture program:

  • capture the year of the event date (report date) and assign it to a
    program rule variable.

I will be thankful if you can assist me.
Sincerely
NG


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

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

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

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

Regards,
Dr. Pamod Amarakoon

MBBS (SL)

MSc (Biomedical Informatics), EMSc (Health Admin), PGCert (MedEd), CEH

Medical Officer in Health Informatics

Nutrition Coordination Division

Ministry of Health, Nutrition and Indigenous Medicine,

Sri Lanka

Confidentiality Notice: the information contained in this email and any attachments may be legally privileged and confidential. If you are not an intended recipient, you are hereby notified that any dissemination, distribution, or copying of this e-mail is strictly prohibited. If you have received this e-mail in error, please notify the sender and permanently delete the e-mail and any attachments immediately. You should not retain, copy or use this e-mail or any attachments for any purpose, nor disclose all or any part of the contents to any other person.

Nada Ghosn, MD

Head, Epidemiology Surveillance Program (Esumoh)

Ministry of Public Health

Beirut, Museum square

Lebanon

Tel +961.1.614194

Fax +961.1.610920

Email esumohleb@gmail.com, esumoh@moph.gov.lb

Website www.moph.gov.lb

Hi Nada,

Just wondering whether you are using the standard data entry form or a custom form. I’m not really sure whether there is a function to display selected org unit name. This is possible using javascript if you are using a custom form though.

···

On Tue, Jan 2, 2018 at 12:04 AM, Nada Ghosn esumohleb@gmail.com wrote:

Good evening,
Thank you again for your prompt reply.

I shall test the new program again.

I will be thankful if you can assist me in the following query:

how to create a data element to retain the name of the orgunit.

Sincerely

Nada

On Mon, Jan 1, 2018 at 9:15 PM, Pamod Amarakoon pamodm@gmail.com wrote:

Hi Nada,

It should come automatically if you already have a data element for the age field and if you have applied a rule to assign the value of the expression above to the data element.


Nada Ghosn, MD

Head, Epidemiology Surveillance Program (Esumoh)

Ministry of Public Health

Beirut, Museum square

Lebanon

Tel +961.1.614194

Fax +961.1.610920

Email esumohleb@gmail.com, esumoh@moph.gov.lb

Website www.moph.gov.lb

On Mon, Jan 1, 2018 at 11:17 PM, Nada Ghosn esumohleb@gmail.com wrote:

Good evening,
Thank you for your prompt reply.

I did the expression and it works.

However, i have to click on the field (year) to get the value.

I will be thankful if you can advise on how to get the value automatically without having to click in the target field (year)

Sincerely

NG

Regards,
Dr. Pamod Amarakoon

MBBS (SL)

MSc (Biomedical Informatics), EMSc (Health Admin), PGCert (MedEd), CEH

Medical Officer in Health Informatics

Nutrition Coordination Division

Ministry of Health, Nutrition and Indigenous Medicine,

Sri Lanka

Confidentiality Notice: the information contained in this email and any attachments may be legally privileged and confidential. If you are not an intended recipient, you are hereby notified that any dissemination, distribution, or copying of this e-mail is strictly prohibited. If you have received this e-mail in error, please notify the sender and permanently delete the e-mail and any attachments immediately. You should not retain, copy or use this e-mail or any attachments for any purpose, nor disclose all or any part of the contents to any other person.

On Mon, Jan 1, 2018 at 8:19 PM, Pamod Amarakoon pamodm@gmail.com wrote:

Hi Nada,

Best wishes for 2018 !

Regarding your query I assume the problem you are facing with is how to obtain the year from the event date. Considering the date format you can get the string value of the year by obtaining the first 4 digits from the left side of the value for the event date. So I suggest you use the following function.

d2:left(V{event_date}, 4)

Hope this helps.

Nada Ghosn, MD

Head, Epidemiology Surveillance Program (Esumoh)

Ministry of Public Health

Beirut, Museum square

Lebanon

Tel +961.1.614194

Fax +961.1.610920

Email esumohleb@gmail.com, esumoh@moph.gov.lb

Website www.moph.gov.lb

On Mon, Jan 1, 2018 at 9:35 PM, Nada Ghosn esumohleb@gmail.com wrote:

Nada Ghosn, MD

Head, Epidemiology Surveillance Program (Esumoh)

Ministry of Public Health

Beirut, Museum square

Lebanon

Tel +961.1.614194

Fax +961.1.610920

Email esumohleb@gmail.com, esumoh@moph.gov.lb

Website www.moph.gov.lb

Hello,
Best wishes for 2018.

I am trying to do the following in an event-capture program:

  • capture the year of the event date (report date) and assign it to a
    program rule variable.

I will be thankful if you can assist me.
Sincerely
NG


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

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

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

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

Regards,
Dr. Pamod Amarakoon

MBBS (SL)

MSc (Biomedical Informatics), EMSc (Health Admin), PGCert (MedEd), CEH

Medical Officer in Health Informatics

Nutrition Coordination Division

Ministry of Health, Nutrition and Indigenous Medicine,

Sri Lanka

Confidentiality Notice: the information contained in this email and any attachments may be legally privileged and confidential. If you are not an intended recipient, you are hereby notified that any dissemination, distribution, or copying of this e-mail is strictly prohibited. If you have received this e-mail in error, please notify the sender and permanently delete the e-mail and any attachments immediately. You should not retain, copy or use this e-mail or any attachments for any purpose, nor disclose all or any part of the contents to any other person.

Regards,
Dr. Pamod Amarakoon

MBBS (SL)

MSc (Biomedical Informatics), EMSc (Health Admin), PGCert (MedEd), CEH

Medical Officer in Health Informatics

Nutrition Coordination Division

Ministry of Health, Nutrition and Indigenous Medicine,

Sri Lanka

Confidentiality Notice: the information contained in this email and any attachments may be legally privileged and confidential. If you are not an intended recipient, you are hereby notified that any dissemination, distribution, or copying of this e-mail is strictly prohibited. If you have received this e-mail in error, please notify the sender and permanently delete the e-mail and any attachments immediately. You should not retain, copy or use this e-mail or any attachments for any purpose, nor disclose all or any part of the contents to any other person.

Hi Nada,

there is a variable that you can use to get the orgunit code in program rules, but not the orgunit name.

The variable is addressed with V{orgunit_code}. For tracker programs this will be the enrolling orgunit, while for single event programs this will be the event orgunit.

See table 19.14: 19.5.6. Reference information: Operators and functions to use in program rule expression

Markus

···

On Tue, Jan 2, 2018 at 12:04 AM, Nada Ghosn esumohleb@gmail.com wrote:

Good evening,
Thank you again for your prompt reply.

I shall test the new program again.

I will be thankful if you can assist me in the following query:

how to create a data element to retain the name of the orgunit.

Sincerely

Nada

On Mon, Jan 1, 2018 at 9:15 PM, Pamod Amarakoon pamodm@gmail.com wrote:

Hi Nada,

It should come automatically if you already have a data element for the age field and if you have applied a rule to assign the value of the expression above to the data element.


Nada Ghosn, MD

Head, Epidemiology Surveillance Program (Esumoh)

Ministry of Public Health

Beirut, Museum square

Lebanon

Tel +961.1.614194

Fax +961.1.610920

Email esumohleb@gmail.com, esumoh@moph.gov.lb

Website www.moph.gov.lb

On Mon, Jan 1, 2018 at 11:17 PM, Nada Ghosn esumohleb@gmail.com wrote:

Good evening,
Thank you for your prompt reply.

I did the expression and it works.

However, i have to click on the field (year) to get the value.

I will be thankful if you can advise on how to get the value automatically without having to click in the target field (year)

Sincerely

NG

Regards,
Dr. Pamod Amarakoon

MBBS (SL)

MSc (Biomedical Informatics), EMSc (Health Admin), PGCert (MedEd), CEH

Medical Officer in Health Informatics

Nutrition Coordination Division

Ministry of Health, Nutrition and Indigenous Medicine,

Sri Lanka

Confidentiality Notice: the information contained in this email and any attachments may be legally privileged and confidential. If you are not an intended recipient, you are hereby notified that any dissemination, distribution, or copying of this e-mail is strictly prohibited. If you have received this e-mail in error, please notify the sender and permanently delete the e-mail and any attachments immediately. You should not retain, copy or use this e-mail or any attachments for any purpose, nor disclose all or any part of the contents to any other person.

On Mon, Jan 1, 2018 at 8:19 PM, Pamod Amarakoon pamodm@gmail.com wrote:

Hi Nada,

Best wishes for 2018 !

Regarding your query I assume the problem you are facing with is how to obtain the year from the event date. Considering the date format you can get the string value of the year by obtaining the first 4 digits from the left side of the value for the event date. So I suggest you use the following function.

d2:left(V{event_date}, 4)

Hope this helps.

Nada Ghosn, MD

Head, Epidemiology Surveillance Program (Esumoh)

Ministry of Public Health

Beirut, Museum square

Lebanon

Tel +961.1.614194

Fax +961.1.610920

Email esumohleb@gmail.com, esumoh@moph.gov.lb

Website www.moph.gov.lb

On Mon, Jan 1, 2018 at 9:35 PM, Nada Ghosn esumohleb@gmail.com wrote:

Nada Ghosn, MD

Head, Epidemiology Surveillance Program (Esumoh)

Ministry of Public Health

Beirut, Museum square

Lebanon

Tel +961.1.614194

Fax +961.1.610920

Email esumohleb@gmail.com, esumoh@moph.gov.lb

Website www.moph.gov.lb

Hello,
Best wishes for 2018.

I am trying to do the following in an event-capture program:

  • capture the year of the event date (report date) and assign it to a
    program rule variable.

I will be thankful if you can assist me.
Sincerely
NG


Mailing list: https://launchpad.net/~dhis2-users
Post to : dhis2-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~dhis2-users
More help : https://help.launchpad.net/ListHelp

Regards,
Dr. Pamod Amarakoon

MBBS (SL)

MSc (Biomedical Informatics), EMSc (Health Admin), PGCert (MedEd), CEH

Medical Officer in Health Informatics

Nutrition Coordination Division

Ministry of Health, Nutrition and Indigenous Medicine,

Sri Lanka

Confidentiality Notice: the information contained in this email and any attachments may be legally privileged and confidential. If you are not an intended recipient, you are hereby notified that any dissemination, distribution, or copying of this e-mail is strictly prohibited. If you have received this e-mail in error, please notify the sender and permanently delete the e-mail and any attachments immediately. You should not retain, copy or use this e-mail or any attachments for any purpose, nor disclose all or any part of the contents to any other person.

Regards,
Dr. Pamod Amarakoon

MBBS (SL)

MSc (Biomedical Informatics), EMSc (Health Admin), PGCert (MedEd), CEH

Medical Officer in Health Informatics

Nutrition Coordination Division

Ministry of Health, Nutrition and Indigenous Medicine,

Sri Lanka

Confidentiality Notice: the information contained in this email and any attachments may be legally privileged and confidential. If you are not an intended recipient, you are hereby notified that any dissemination, distribution, or copying of this e-mail is strictly prohibited. If you have received this e-mail in error, please notify the sender and permanently delete the e-mail and any attachments immediately. You should not retain, copy or use this e-mail or any attachments for any purpose, nor disclose all or any part of the contents to any other person.

Good evening,
Thank you for your message.

I have tried the following:

  • having specific code for each target orgunit

  • having a data element: de_ic_orgunit

  • having a program event capture (pgm_icu) where de_ic_orgunit is included in the form

  • having a program rule: pr_ic_orgunit_code, where no condition is specified, and where action is to attribute value to data element (de_ic_orgunit), with the following expression V{orgunit_code}

When testing the procedure, it did not work. The orgunit code did not appear in the target data element.

Did i do some mistake in the procedure?

Sincerely

Nada

···

On Fri, Jan 5, 2018 at 5:31 PM, Markus Bekken markus@dhis2.org wrote:

Hi Nada,
there is a variable that you can use to get the orgunit code in program rules, but not the orgunit name.

The variable is addressed with V{orgunit_code}. For tracker programs this will be the enrolling orgunit, while for single event programs this will be the event orgunit.

See table 19.14: 19.5.6. Reference information: Operators and functions to use in program rule expression

Markus

  1. jan. 2018 kl. 17.46 skrev Pamod Amarakoon pamodm@gmail.com:

Hi Nada,

Just wondering whether you are using the standard data entry form or a custom form. I’m not really sure whether there is a function to display selected org unit name. This is possible using javascript if you are using a custom form though.


Mailing list: https://launchpad.net/~dhis2-users
Post to : dhis2-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~dhis2-users
More help : https://help.launchpad.net/ListHelp

Good evening,
Thank you again for your prompt reply.

I shall test the new program again.

I will be thankful if you can assist me in the following query:

how to create a data element to retain the name of the orgunit.

Sincerely

Nada

On Tue, Jan 2, 2018 at 12:04 AM, Nada Ghosn esumohleb@gmail.com wrote:


Regards,
Dr. Pamod Amarakoon

MBBS (SL)

MSc (Biomedical Informatics), EMSc (Health Admin), PGCert (MedEd), CEH

Medical Officer in Health Informatics

Nutrition Coordination Division

Ministry of Health, Nutrition and Indigenous Medicine,

Sri Lanka

Confidentiality Notice: the information contained in this email and any attachments may be legally privileged and confidential. If you are not an intended recipient, you are hereby notified that any dissemination, distribution, or copying of this e-mail is strictly prohibited. If you have received this e-mail in error, please notify the sender and permanently delete the e-mail and any attachments immediately. You should not retain, copy or use this e-mail or any attachments for any purpose, nor disclose all or any part of the contents to any other person.

Hi Nada,

It should come automatically if you already have a data element for the age field and if you have applied a rule to assign the value of the expression above to the data element.

On Mon, Jan 1, 2018 at 9:15 PM, Pamod Amarakoon pamodm@gmail.com wrote:


Nada Ghosn, MD

Head, Epidemiology Surveillance Program (Esumoh)

Ministry of Public Health

Beirut, Museum square

Lebanon

Tel +961.1.614194

Fax +961.1.610920

Email esumohleb@gmail.com, esumoh@moph.gov.lb

Website www.moph.gov.lb

Good evening,
Thank you for your prompt reply.

I did the expression and it works.

However, i have to click on the field (year) to get the value.

I will be thankful if you can advise on how to get the value automatically without having to click in the target field (year)

Sincerely

NG

On Mon, Jan 1, 2018 at 11:17 PM, Nada Ghosn esumohleb@gmail.com wrote:

Regards,
Dr. Pamod Amarakoon

MBBS (SL)

MSc (Biomedical Informatics), EMSc (Health Admin), PGCert (MedEd), CEH

Medical Officer in Health Informatics

Nutrition Coordination Division

Ministry of Health, Nutrition and Indigenous Medicine,

Sri Lanka

Confidentiality Notice: the information contained in this email and any attachments may be legally privileged and confidential. If you are not an intended recipient, you are hereby notified that any dissemination, distribution, or copying of this e-mail is strictly prohibited. If you have received this e-mail in error, please notify the sender and permanently delete the e-mail and any attachments immediately. You should not retain, copy or use this e-mail or any attachments for any purpose, nor disclose all or any part of the contents to any other person.

Hi Nada,

Best wishes for 2018 !

Regarding your query I assume the problem you are facing with is how to obtain the year from the event date. Considering the date format you can get the string value of the year by obtaining the first 4 digits from the left side of the value for the event date. So I suggest you use the following function.

d2:left(V{event_date}, 4)

Hope this helps.

On Mon, Jan 1, 2018 at 8:19 PM, Pamod Amarakoon pamodm@gmail.com wrote:

Nada Ghosn, MD

Head, Epidemiology Surveillance Program (Esumoh)

Ministry of Public Health

Beirut, Museum square

Lebanon

Tel +961.1.614194

Fax +961.1.610920

Email esumohleb@gmail.com, esumoh@moph.gov.lb

Website www.moph.gov.lb

Nada Ghosn, MD

Head, Epidemiology Surveillance Program (Esumoh)

Ministry of Public Health

Beirut, Museum square

Lebanon

Tel +961.1.614194

Fax +961.1.610920

Email esumohleb@gmail.com, esumoh@moph.gov.lb

Website www.moph.gov.lb

Hello,
Best wishes for 2018.

I am trying to do the following in an event-capture program:

  • capture the year of the event date (report date) and assign it to a
    program rule variable.

I will be thankful if you can assist me.
Sincerely
NG


Mailing list: https://launchpad.net/~dhis2-users
Post to : dhis2-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~dhis2-users
More help : https://help.launchpad.net/ListHelp

On Mon, Jan 1, 2018 at 9:35 PM, Nada Ghosn esumohleb@gmail.com wrote:

Regards,
Dr. Pamod Amarakoon

MBBS (SL)

MSc (Biomedical Informatics), EMSc (Health Admin), PGCert (MedEd), CEH

Medical Officer in Health Informatics

Nutrition Coordination Division

Ministry of Health, Nutrition and Indigenous Medicine,

Sri Lanka

Confidentiality Notice: the information contained in this email and any attachments may be legally privileged and confidential. If you are not an intended recipient, you are hereby notified that any dissemination, distribution, or copying of this e-mail is strictly prohibited. If you have received this e-mail in error, please notify the sender and permanently delete the e-mail and any attachments immediately. You should not retain, copy or use this e-mail or any attachments for any purpose, nor disclose all or any part of the contents to any other person.

Nada Ghosn, MD

Head, Epidemiology Surveillance Program (Esumoh)

Ministry of Public Health

Beirut, Museum square

Lebanon

Tel +961.1.614194

Fax +961.1.610920

Email esumohleb@gmail.com, esumoh@moph.gov.lb

Website www.moph.gov.lb