Greetings + new DHIS patient module

So we are thinking of an algorithm to generate the id for the whole country,
but not depend on the organisation unit. It should only depend on patient
information and the time of creating...

A UUID perhaps? Seems to be the only way to guarantee you will end up
with a unique ID, especially in a federated setting. Otherwise,
national identity numbers, but there are privacy issues here to
consider.

http://java.sun.com/j2se/1.5.0/docs/api/java/util/UUID.html

Regards,
Jason

I think the OpenMRS project has considered this question extensively (and many others that are relevant for a patient system).

Knut

···

On Mon, Feb 1, 2010 at 7:31 AM, Jason Pickering jason.p.pickering@gmail.com wrote:

So we are thinking of an algorithm to generate the id for the whole country,

but not depend on the organisation unit. It should only depend on patient

information and the time of creating…

A UUID perhaps? Seems to be the only way to guarantee you will end up

with a unique ID, especially in a federated setting. Otherwise,

national identity numbers, but there are privacy issues here to

consider.

http://java.sun.com/j2se/1.5.0/docs/api/java/util/UUID.html

Regards,

Jason


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


Cheers,
Knut Staring

Hi Abyot and Others,

I tested the **UpdatePatientAttributeValues **function. It doesn’t show anything. I think if we have EditPatient, we don’t need PatientAttributeValues.

About enter name for Patient and Patient attribute

  • The validate function ( required_group {validate…) doesn’t allow to enter Vietnamese in Add/Update patient, Add/Update PatientAttribute ,…

VD: Châu → Warning message: Please Letters, numbers, spaces and underscores only.

  • For mother, we have attributes, such as age, pre-pregnancy, housenumber, street name. We want to enter street name next to housenumber. So, I think we have to sort attributes in groups ?

Patient Identifier Type

  • In Add Patient form, only show Patient Identifier Type when object has age less then 5. In Mother-Child Record in Vietnam, besides the children object, we also manage children less then or equal 15. How do you think if we have a parameter ( user input ) for it ?

Dataentry

Program Stages History/Plan

Sau khi sanh (After to born):

                                                                        Scheduled For 2010-02-04

Kết quả (Result):

                                                                        Scheduled For 2010-02-04

Trước khi sanh (Before to born):

                                                                        Scheduled For 2010-02-01 

The stages aren’t listed in order. I want them to list, as follows : Before - After - Result.

Yes/No datatype shown dataentry is a combobox. How do you think if we use a checkbox ?

- Programs for patient

Why don’t assign program for patient when to add a new patient. And in the future, if the patient attends other programs, we will assign them again.

  • RelationShip

I can’t create relationship between two objects.

Best regards,

···

================================
Châu Thu Trân

HISP Viet Nam
Email: tran.hispvietnam@gmail.com

Cell phone: +84 97 324 1542

On Mon, Feb 1, 2010 at 3:23 PM, Knut Staring knutst@gmail.com wrote:

I think the OpenMRS project has considered this question extensively (and many others that are relevant for a patient system).

Knut

On Mon, Feb 1, 2010 at 7:31 AM, Jason Pickering jason.p.pickering@gmail.com wrote:

So we are thinking of an algorithm to generate the id for the whole country,

but not depend on the organisation unit. It should only depend on patient

information and the time of creating…

A UUID perhaps? Seems to be the only way to guarantee you will end up

with a unique ID, especially in a federated setting. Otherwise,

national identity numbers, but there are privacy issues here to

consider.

http://java.sun.com/j2se/1.5.0/docs/api/java/util/UUID.html

Regards,

Jason


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


Cheers,
Knut Staring


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

Hi,

Hi Abyot and Others,

I tested the **UpdatePatientAttributeValues **function. It doesn’t show anything. I think if we have EditPatient, we don’t need PatientAttributeValues.

Yeah, this is a bug, we changed Attribute object so this function should be updated . I will fix that.
Let’s keep it there for a while, later when everything is fine then we can have a look at all the functions and decide whether to keep it or not.

About enter name for Patient and Patient attribute

  • The validate function ( required_group {validate…) doesn’t allow to enter Vietnamese in Add/Update patient, Add/Update PatientAttribute ,…

VD: Châu → Warning message: Please Letters, numbers, spaces and underscores only.

This is just rule of jquery validation, I can remove that .

  • For mother, we have attributes, such as age, pre-pregnancy, housenumber, street name. We want to enter street name next to housenumber. So, I think we have to sort attributes in groups ?

Yeah sure. there should be a sort-order while assign attribute to attribute group.

Patient Identifier Type

  • In Add Patient form, only show Patient Identifier Type when object has age less then 5. In Mother-Child Record in Vietnam, besides the children object, we also manage children less then or equal 15. How do you think if we have a parameter ( user input ) for it ?

Current, we have added a boolean field “underAge” in Patient object. In the registration form, there will be a checkbox call “Is Underage”

user have to check that to define this patient is a child. By this way, we don’t hardcode the age <5 or < 15.

I’m working on this function, will update you when i finish.

Dataentry

Program Stages History/Plan

Sau khi sanh (After to born):

                                                                        Scheduled For 2010-02-04

Kết quả (Result):

                                                                        Scheduled For 2010-02-04

Trước khi sanh (Before to born):

                                                                        Scheduled For 2010-02-01 

The stages aren’t listed in order. I want them to list, as follows : Before - After - Result.

Have not touched this yet, Will have a look.

Yes/No datatype shown dataentry is a combobox. How do you think if we use a checkbox ?

We can do this in the default dataetry, but not in custom dataentry.

In custom dataentry there is a checkbox right beside each entry field ( textbox or combobox ). If user check on this checkbox, means that the data value has just been entered is provided by another facility. So if we replace boolean entryfield by a checkbox… there will be two checkboxes that stay beside each other, I think it may confuse user.

- Programs for patient

Why don’t assign program for patient when to add a new patient. And in the future, if the patient attends other programs, we will assign them again.

This should make the registration function becomes…complicated.
Current, we already put a lot of things into the patient registration form : Patient Attributes , Patient Identifiers, under age things.

Program enrollment is not a step of Patient Registration. It should be done after the registration I think.

  • RelationShip

I can’t create relationship between two objects.

It worked here…I will test it again…

···

On Mon, Mar 1, 2010 at 11:13 AM, Chau Thu Tran tran.hispvietnam@gmail.com wrote:

Viet Nguyen

Hi,

Hi Abyot and Others,

I tested the **UpdatePatientAttributeValues **function. It doesn’t show anything. I think if we have EditPatient, we don’t need PatientAttributeValues.

Yeah, this is a bug, we changed Attribute object so this function should be updated . I will fix that.
Let’s keep it there for a while, later when everything is fine then we can have a look at all the functions and decide whether to keep it or not.

About enter name for Patient and Patient attribute

  • The validate function ( required_group {validate…) doesn’t allow to enter Vietnamese in Add/Update patient, Add/Update PatientAttribute ,…

VD: Châu → Warning message: Please Letters, numbers, spaces and underscores only.

This is just rule of jquery validation, I can remove that .

  • For mother, we have attributes, such as age, pre-pregnancy, housenumber, street name. We want to enter street name next to housenumber. So, I think we have to sort attributes in groups ?

Yeah sure. there should be a sort-order while assign attribute to attribute group.

Patient Identifier Type

  • In Add Patient form, only show Patient Identifier Type when object has age less then 5. In Mother-Child Record in Vietnam, besides the children object, we also manage children less then or equal 15. How do you think if we have a parameter ( user input ) for it ?

Current, we have added a boolean field “underAge” in Patient object. In the registration form, there will be a checkbox call “Is Underage”

user have to check that to define this patient is a child. By this way, we don’t hardcode the age <5 or < 15.

I’m working on this function, will update you when i finish.

Dataentry

Program Stages History/Plan

Sau khi sanh (After to born):

                                                                        Scheduled For 2010-02-04

Kết quả (Result):

                                                                        Scheduled For 2010-02-04

Trước khi sanh (Before to born):

                                                                        Scheduled For 2010-02-01 

The stages aren’t listed in order. I want them to list, as follows : Before - After - Result.

Have not touched this yet, Will have a look.

Have you sorted your program stages?

···

On Mon, Mar 1, 2010 at 9:22 AM, Viet Nguyen phamquocviet@gmail.com wrote:

On Mon, Mar 1, 2010 at 11:13 AM, Chau Thu Tran tran.hispvietnam@gmail.com wrote:

Yes/No datatype shown dataentry is a combobox. How do you think if we use a checkbox ?

We can do this in the default dataetry, but not in custom dataentry.

In custom dataentry there is a checkbox right beside each entry field ( textbox or combobox ). If user check on this checkbox, means that the data value has just been entered is provided by another facility. So if we replace boolean entryfield by a checkbox… there will be two checkboxes that stay beside each other, I think it may confuse user.

- Programs for patient

Why don’t assign program for patient when to add a new patient. And in the future, if the patient attends other programs, we will assign them again.

This should make the registration function becomes…complicated.
Current, we already put a lot of things into the patient registration form : Patient Attributes , Patient Identifiers, under age things.

Program enrollment is not a step of Patient Registration. It should be done after the registration I think.

  • RelationShip

I can’t create relationship between two objects.

It worked here…I will test it again…

Viet Nguyen

Hi all,

Sorry. I sorted them. It’s Ok.

···

================================
Châu Thu Trân
HISP Viet Nam
Email: tran.hispvietnam@gmail.com

Cell phone: +84 97 324 1542

On Mon, Mar 1, 2010 at 3:38 PM, Abyot Gizaw abyota@gmail.com wrote:

On Mon, Mar 1, 2010 at 9:22 AM, Viet Nguyen phamquocviet@gmail.com wrote:

Hi,

On Mon, Mar 1, 2010 at 11:13 AM, Chau Thu Tran tran.hispvietnam@gmail.com wrote:

Hi Abyot and Others,

I tested the **UpdatePatientAttributeValues **function. It doesn’t show anything. I think if we have EditPatient, we don’t need PatientAttributeValues.

Yeah, this is a bug, we changed Attribute object so this function should be updated . I will fix that.
Let’s keep it there for a while, later when everything is fine then we can have a look at all the functions and decide whether to keep it or not.

About enter name for Patient and Patient attribute

  • The validate function ( required_group {validate…) doesn’t allow to enter Vietnamese in Add/Update patient, Add/Update PatientAttribute ,…

VD: Châu → Warning message: Please Letters, numbers, spaces and underscores only.

This is just rule of jquery validation, I can remove that .

  • For mother, we have attributes, such as age, pre-pregnancy, housenumber, street name. We want to enter street name next to housenumber. So, I think we have to sort attributes in groups ?

Yeah sure. there should be a sort-order while assign attribute to attribute group.

Patient Identifier Type

  • In Add Patient form, only show Patient Identifier Type when object has age less then 5. In Mother-Child Record in Vietnam, besides the children object, we also manage children less then or equal 15. How do you think if we have a parameter ( user input ) for it ?

Current, we have added a boolean field “underAge” in Patient object. In the registration form, there will be a checkbox call “Is Underage”

user have to check that to define this patient is a child. By this way, we don’t hardcode the age <5 or < 15.

I’m working on this function, will update you when i finish.

Dataentry

Program Stages History/Plan

Sau khi sanh (After to born):

                                                                        Scheduled For 2010-02-04

Kết quả (Result):

                                                                        Scheduled For 2010-02-04

Trước khi sanh (Before to born):

                                                                        Scheduled For 2010-02-01 

The stages aren’t listed in order. I want them to list, as follows : Before - After - Result.

Have not touched this yet, Will have a look.

Have you sorted your program stages?

Yes/No datatype shown dataentry is a combobox. How do you think if we use a checkbox ?

We can do this in the default dataetry, but not in custom dataentry.

In custom dataentry there is a checkbox right beside each entry field ( textbox or combobox ). If user check on this checkbox, means that the data value has just been entered is provided by another facility. So if we replace boolean entryfield by a checkbox… there will be two checkboxes that stay beside each other, I think it may confuse user.

- Programs for patient

Why don’t assign program for patient when to add a new patient. And in the future, if the patient attends other programs, we will assign them again.

This should make the registration function becomes…complicated.
Current, we already put a lot of things into the patient registration form : Patient Attributes , Patient Identifiers, under age things.

Program enrollment is not a step of Patient Registration. It should be done after the registration I think.

  • RelationShip

I can’t create relationship between two objects.

It worked here…I will test it again…

Viet Nguyen

Hi Viet

Hi,

Hi Abyot and Others,

I tested the **UpdatePatientAttributeValues **function. It doesn’t show anything. I think if we have EditPatient, we don’t need PatientAttributeValues.

Yeah, this is a bug, we changed Attribute object so this function should be updated . I will fix that.
Let’s keep it there for a while, later when everything is fine then we can have a look at all the functions and decide whether to keep it or not.

About enter name for Patient and Patient attribute

  • The validate function ( required_group {validate…) doesn’t allow to enter Vietnamese in Add/Update patient, Add/Update PatientAttribute ,…

VD: Châu → Warning message: Please Letters, numbers, spaces and underscores only.

This is just rule of jquery validation, I can remove that .

This exposes quite an interesting problem regarding the use of regex based validators - such as the jquery validation plugin. I see that you made some mods to the plugin to allow internationalized messages, nut the bigger problem may be with the underlying regexes themselves. In Jason’s broader vision of regex use we need to take into account internationalized regexes. So for example [a-zA-Z] looks useful but it is of course not universally applicable. If we needed to match Gujerati characters we would need something like [\u0A80-\u0AFF].

Not wanting to hijack this thread, I think we need to add this internationalisation requirement to the regex blueprint and maybe discuss it elsewhere. And meanwhile beware of things like “alphanumeric” in the jquery plugin as it clearly seems to make assumptions about character ranges.

Regards
Bob

···

On 1 March 2010 08:22, Viet Nguyen phamquocviet@gmail.com wrote:

On Mon, Mar 1, 2010 at 11:13 AM, Chau Thu Tran tran.hispvietnam@gmail.com wrote:

  • For mother, we have attributes, such as age, pre-pregnancy, housenumber, street name. We want to enter street name next to housenumber. So, I think we have to sort attributes in groups ?

Yeah sure. there should be a sort-order while assign attribute to attribute group.

Patient Identifier Type

  • In Add Patient form, only show Patient Identifier Type when object has age less then 5. In Mother-Child Record in Vietnam, besides the children object, we also manage children less then or equal 15. How do you think if we have a parameter ( user input ) for it ?

Current, we have added a boolean field “underAge” in Patient object. In the registration form, there will be a checkbox call “Is Underage”

user have to check that to define this patient is a child. By this way, we don’t hardcode the age <5 or < 15.

I’m working on this function, will update you when i finish.

Dataentry

Program Stages History/Plan

Sau khi sanh (After to born):

                                                                        Scheduled For 2010-02-04

Kết quả (Result):

                                                                        Scheduled For 2010-02-04

Trước khi sanh (Before to born):

                                                                        Scheduled For 2010-02-01 

The stages aren’t listed in order. I want them to list, as follows : Before - After - Result.

Have not touched this yet, Will have a look.

Yes/No datatype shown dataentry is a combobox. How do you think if we use a checkbox ?

We can do this in the default dataetry, but not in custom dataentry.

In custom dataentry there is a checkbox right beside each entry field ( textbox or combobox ). If user check on this checkbox, means that the data value has just been entered is provided by another facility. So if we replace boolean entryfield by a checkbox… there will be two checkboxes that stay beside each other, I think it may confuse user.

- Programs for patient

Why don’t assign program for patient when to add a new patient. And in the future, if the patient attends other programs, we will assign them again.

This should make the registration function becomes…complicated.
Current, we already put a lot of things into the patient registration form : Patient Attributes , Patient Identifiers, under age things.

Program enrollment is not a step of Patient Registration. It should be done after the registration I think.

  • RelationShip

I can’t create relationship between two objects.

It worked here…I will test it again…

Viet Nguyen


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

Ok, I understand the problem. Will remove the alphanumeric things for now. I’m not sure how to integrate this client validation with what Jason did…will try to have a look at that when I have time.

···

On Mon, Mar 1, 2010 at 4:02 PM, Bob Jolliffe bobjolliffe@gmail.com wrote:

Hi Viet

On 1 March 2010 08:22, Viet Nguyen phamquocviet@gmail.com wrote:

Hi,

On Mon, Mar 1, 2010 at 11:13 AM, Chau Thu Tran tran.hispvietnam@gmail.com wrote:

Hi Abyot and Others,

I tested the **UpdatePatientAttributeValues **function. It doesn’t show anything. I think if we have EditPatient, we don’t need PatientAttributeValues.

Yeah, this is a bug, we changed Attribute object so this function should be updated . I will fix that.
Let’s keep it there for a while, later when everything is fine then we can have a look at all the functions and decide whether to keep it or not.

About enter name for Patient and Patient attribute

  • The validate function ( required_group {validate…) doesn’t allow to enter Vietnamese in Add/Update patient, Add/Update PatientAttribute ,…

VD: Châu → Warning message: Please Letters, numbers, spaces and underscores only.

This is just rule of jquery validation, I can remove that .

This exposes quite an interesting problem regarding the use of regex based validators - such as the jquery validation plugin. I see that you made some mods to the plugin to allow internationalized messages, nut the bigger problem may be with the underlying regexes themselves. In Jason’s broader vision of regex use we need to take into account internationalized regexes. So for example [a-zA-Z] looks useful but it is of course not universally applicable. If we needed to match Gujerati characters we would need something like [\u0A80-\u0AFF].

Not wanting to hijack this thread, I think we need to add this internationalisation requirement to the regex blueprint and maybe discuss it elsewhere. And meanwhile beware of things like “alphanumeric” in the jquery plugin as it clearly seems to make assumptions about character ranges.


Viet Nguyen

Hi there. Well, nothing has been done yet, but we have been discussing
the need for field-level validation with the use of regular
expressions. I am not sure this impacts the blue print so much
actually, however it would seem there would possibly need to be
another field added to the regex to record which language the
particular regex would apply to if the field is language related.

I can make the update to the blueprint when I get a chance.

Best regards,
Jason

···

On Mon, Mar 1, 2010 at 1:20 PM, Viet Nguyen <phamquocviet@gmail.com> wrote:

On Mon, Mar 1, 2010 at 4:02 PM, Bob Jolliffe <bobjolliffe@gmail.com> wrote:

Hi Viet

On 1 March 2010 08:22, Viet Nguyen <phamquocviet@gmail.com> wrote:

Hi,

On Mon, Mar 1, 2010 at 11:13 AM, Chau Thu Tran >>> <tran.hispvietnam@gmail.com> wrote:

Hi Abyot and Others,
I tested the UpdatePatientAttributeValues function. It doesn't show
anything. I think if we have EditPatient, we don't
need PatientAttributeValues.

Yeah, this is a bug, we changed Attribute object so this function should
be updated . I will fix that.
Let's keep it there for a while, later when everything is fine then we
can have a look at all the functions and decide whether to keep it or not.

About enter name for Patient and Patient attribute
- The validate function ( required_group {validate...) doesn't
allow to enter Vietnamese in Add/Update patient, Add/Update PatientAttribute
,....
VD: Châu --> Warning message: Please Letters, numbers, spaces and
underscores only.

This is just rule of jquery validation, I can remove that .

This exposes quite an interesting problem regarding the use of regex based
validators - such as the jquery validation plugin. I see that you made some
mods to the plugin to allow internationalized messages, nut the bigger
problem may be with the underlying regexes themselves. In Jason's broader
vision of regex use we need to take into account internationalized regexes.
So for example [a-zA-Z] looks useful but it is of course not universally
applicable. If we needed to match Gujerati characters we would need
something like [\u0A80-\u0AFF].

Not wanting to hijack this thread, I think we need to add this
internationalisation requirement to the regex blueprint and maybe discuss it
elsewhere. And meanwhile beware of things like "alphanumeric" in the jquery
plugin as it clearly seems to make assumptions about character ranges.

Ok, I understand the problem. Will remove the alphanumeric things for now.
I'm not sure how to integrate this client validation with what Jason
did...will try to have a look at that when I have time.

--
Viet Nguyen

_______________________________________________
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

--
--
Jason P. Pickering
email: jason.p.pickering@gmail.com
tel:+260968395190

Hi,

Just a quick update about Patient registration form functionality :

* Check duplicate :

This function allow user to check for existing patient base on : name , birthdate, age, gender

If there is duplicate patient, a pop up will be showed, with the list of all the duplicated patients.

From this pop up, user can have two options :

  1. Continue create the current patient. So there will be two patients with the same information like above. But their identifiers must be different which will be checked later.
  2. User can choose a patient from the list duplicated patient to update information for him, by click on the button “Update this patient” that follow by each patient in the list. User will then be redirected to the Update Patient page.
    * Under age patient :

Under age patient can be understand as a child. The purpose of this field is not to hard code the age to define a child, like age < 5 or age < 15.

In the registration form, there is a check box named " Is Underage" . User check on this check box to identify the patient is a child. A pop up will be showed after clicking.

The purpose of this pop up is : user must choose a representative for this child. Because , some identifiers that are mandatory ( can be defined in Patient Identifier Type management page ) . But a child can not have those identifier, so we have to inherit those identifier from the child’s representative.

Not all identifier can be inherited, you can defined a PatientIdentiferType is able to inherit or not when creating it. The field name is “Related” … ( God …why didn’t I use" Inheritable" … ) .

If a PatientIdentifierType with “related” = FALSE and “mandatory” = TRUE then user must enter value for it.

Ok, back to the popup, there are two tabs :

  1. Search existing person : user can search for an existing patient in system to be the representative of the child.
  2. Add new person : said this is person, because this is not really a patient, this person is just giving identifier…not enrolling to any program, at least at this step. Of course the record is also saved to the patient table. The form just only include basic information ( name , birthdate, gender… ) and Identifiers. No attributes is needed. Of course user can update attributes for this person later by the Update Patient page.
    One problem in this function that I can not have enough time to do :

In the combo box Relationship Type, there should be Parent and Guardian, I hard coded this. You should create two relationship type with this information before testing this function :

A is to B : Guardian, B is to A : Child
A is to B : Parent , B is to A : Child.

The list of relationship type should be get from the Relationship type table. But if we put everything to the combo box, then user may choose Husband, Wife, or even child…which is so wrong.

My plan is creating an object RelationshipGroup, which should be based on the age…

Anyway, because we are late for releasing this version in India. so hard code for now is the only solution. I will continue working on this, so …please don’t worry…

* System generated identifier :

I looked at the id_gen module from OpenMRS. Well , they have a whole module for this which has many functionality for manage system auto generated identifier.

I can not have enough time for getting all of that. So what I did is just get a piece of code that is used for generate a check digit for the ID.

The format that Indian team chose is : [BirthDate][Gender][XXXXXX][checkdigit]

BirthDate : yyyyMMdd
Gender : Male = 1 ; Female = 0
XXXXXX : a random number with length = 6 ( 0 - 999999 )
checkdigit : generated using Luhn Algorithm ( thanks to OpenMRS guys )

I also changed the way that Abyot generate the birthdate from age ( when user only enter age ) .
It is : todayCalendar.add( Calendar.YEAR, -1 * age );
What Abyot did is
todayCalendar.set( Calendar.DATE, 1 );

      todayCalendar.set( Calendar.MONTH, Calendar.JANUARY );
      todayCalendar.add( Calendar.YEAR, -1 * age );

Because we generate the id base on birthdate , get current date should be better.
Hope this is ok for Abyot…

Each country will have different formats…so I think for current we just can change code when implementing in the country. Building a module for this would take time…

Finally, but almost those things only follow India 's requirements.

Please give comment then we can try to make it more generic…

Regards,

Viet Nguyen

Hi

Hi,

Just a quick update about Patient registration form functionality :

* Check duplicate :

This function allow user to check for existing patient base on : name ,
birthdate, age, gender

If there is duplicate patient, a pop up will be showed, with the list of all
the duplicated patients.

From this pop up, user can have two options :

Continue create the current patient. So there will be two patients with the
same information like above. But their identifiers must be different which
will be checked later.
User can choose a patient from the list duplicated patient to update
information for him, by click on the button "Update this patient" that
follow by each patient in the list. User will then be redirected to the
Update Patient page.

* Under age patient :

Under age patient can be understand as a child. The purpose of this field is
not to hard code the age to define a child, like age < 5 or age < 15.

In the registration form, there is a check box named " Is Underage" . User
check on this check box to identify the patient is a child. A pop up will
be showed after clicking.

The purpose of this pop up is : user must choose a representative for this
child. Because , some identifiers that are mandatory ( can be defined in
Patient Identifier Type management page ) . But a child can not have those
identifier, so we have to inherit those identifier from the child's
representative.

Not all identifier can be inherited, you can defined a PatientIdentiferType
is able to inherit or not when creating it. The field name is "Related"
... ( God ...why didn't I use" Inheritable" .... ) .

If a PatientIdentifierType with "related" = FALSE and "mandatory" = TRUE
then user must enter value for it.

Ok, back to the popup, there are two tabs :

Search existing person : user can search for an existing patient in system
to be the representative of the child.
Add new person : said this is person, because this is not really a patient,
this person is just giving identifier...not enrolling to any program, at
least at this step. Of course the record is also saved to the patient table.
The form just only include basic information ( name , birthdate, gender.. )
and Identifiers. No attributes is needed. Of course user can update
attributes for this person later by the Update Patient page.

One problem in this function that I can not have enough time to do :

In the combo box Relationship Type, there should be Parent and Guardian, I
hard coded this. You should create two relationship type with this
information before testing this function :

A is to B : Guardian, B is to A : Child
A is to B : Parent , B is to A : Child.

The list of relationship type should be get from the Relationship type
table. But if we put everything to the combo box, then user may choose
Husband, Wife, or even child...which is so wrong.

My plan is creating an object RelationshipGroup, which should be based on
the age...

Anyway, because we are late for releasing this version in India. so hard
code for now is the only solution. I will continue working on this, so
...please don't worry...

* System generated identifier :

I looked at the id_gen module from OpenMRS. Well , they have a whole module
for this which has many functionality for manage system auto generated
identifier.

I can not have enough time for getting all of that. So what I did is just
get a piece of code that is used for generate a check digit for the ID.

The format that Indian team chose is :
[BirthDate][Gender][XXXXXX][checkdigit]

Encoding the birthdate and gender into a patient identifier is
considered bad practice. Using the orgunit+random digits would be
much better. It shouldn't matter if the patient "migrates". The
number was simply issued by a particular facility.

Regards
Bob

···

On 3 March 2010 12:20, Viet Nguyen <phamquocviet@gmail.com> wrote:

BirthDate : yyyyMMdd
Gender : Male = 1 ; Female = 0
XXXXXX : a random number with length = 6 ( 0 - 999999 )
checkdigit : generated using Luhn Algorithm ( thanks to OpenMRS guys )

I also changed the way that Abyot generate the birthdate from age ( when
user only enter age ) .
It is : todayCalendar.add( Calendar.YEAR, -1 * age );
What Abyot did is
todayCalendar.set( Calendar.DATE, 1 );
todayCalendar.set( Calendar.MONTH, Calendar.JANUARY );
todayCalendar.add( Calendar.YEAR, -1 * age );
Because we generate the id base on birthdate , get current date should be
better.
Hope this is ok for Abyot....

Each country will have different formats...so I think for current we just
can change code when implementing in the country. Building a module for this
would take time....

Finally, but almost those things only follow India 's requirements.
Please give comment then we can try to make it more generic...

Regards,

Viet Nguyen

Hi bob,

the system generated ID is to one way to identify the case or person. using orgunit you mean the code for that organization unit. In india they have generated a 16 digit ID based on Country, Province,District,Sub-district and facility. but the problem with this is what happen if new district or province is created. In norway the personal id number is ddmmyy+sex+random number. I thougth we cloud use the same but increasing the random number to avoid the duplicate. And its also useful that the person dont have to remember all the 16 or 14 digit number. for the sake of simplicity we used this method.

John

···

On Wed, Mar 3, 2010 at 1:35 PM, Bob Jolliffe bobjolliffe@gmail.com wrote:

Hi

On 3 March 2010 12:20, Viet Nguyen phamquocviet@gmail.com wrote:

Hi,

Just a quick update about Patient registration form functionality :

  • Check duplicate :

This function allow user to check for existing patient base on : name ,

birthdate, age, gender

If there is duplicate patient, a pop up will be showed, with the list of all

the duplicated patients.

From this pop up, user can have two options :

Continue create the current patient. So there will be two patients with the

same information like above. But their identifiers must be different which

will be checked later.

User can choose a patient from the list duplicated patient to update

information for him, by click on the button “Update this patient” that

follow by each patient in the list. User will then be redirected to the

Update Patient page.

  • Under age patient :

Under age patient can be understand as a child. The purpose of this field is

not to hard code the age to define a child, like age < 5 or age < 15.

In the registration form, there is a check box named " Is Underage" . User

check on this check box to identify the patient is a child. A pop up will

be showed after clicking.

The purpose of this pop up is : user must choose a representative for this

child. Because , some identifiers that are mandatory ( can be defined in

Patient Identifier Type management page ) . But a child can not have those

identifier, so we have to inherit those identifier from the child’s

representative.

Not all identifier can be inherited, you can defined a PatientIdentiferType

is able to inherit or not when creating it. The field name is “Related”

… ( God …why didn’t I use" Inheritable" … ) .

If a PatientIdentifierType with “related” = FALSE and “mandatory” = TRUE

then user must enter value for it.

Ok, back to the popup, there are two tabs :

Search existing person : user can search for an existing patient in system

to be the representative of the child.

Add new person : said this is person, because this is not really a patient,

this person is just giving identifier…not enrolling to any program, at

least at this step. Of course the record is also saved to the patient table.

The form just only include basic information ( name , birthdate, gender… )

and Identifiers. No attributes is needed. Of course user can update

attributes for this person later by the Update Patient page.

One problem in this function that I can not have enough time to do :

In the combo box Relationship Type, there should be Parent and Guardian, I

hard coded this. You should create two relationship type with this

information before testing this function :

A is to B : Guardian, B is to A : Child

A is to B : Parent , B is to A : Child.

The list of relationship type should be get from the Relationship type

table. But if we put everything to the combo box, then user may choose

Husband, Wife, or even child…which is so wrong.

My plan is creating an object RelationshipGroup, which should be based on

the age…

Anyway, because we are late for releasing this version in India. so hard

code for now is the only solution. I will continue working on this, so

…please don’t worry…

  • System generated identifier :

I looked at the id_gen module from OpenMRS. Well , they have a whole module

for this which has many functionality for manage system auto generated

identifier.

I can not have enough time for getting all of that. So what I did is just

get a piece of code that is used for generate a check digit for the ID.

The format that Indian team chose is :

[BirthDate][Gender][XXXXXX][checkdigit]

Encoding the birthdate and gender into a patient identifier is

considered bad practice. Using the orgunit+random digits would be

much better. It shouldn’t matter if the patient “migrates”. The

number was simply issued by a particular facility.

Regards

Bob

BirthDate : yyyyMMdd

Gender : Male = 1 ; Female = 0

XXXXXX : a random number with length = 6 ( 0 - 999999 )

checkdigit : generated using Luhn Algorithm ( thanks to OpenMRS guys )

I also changed the way that Abyot generate the birthdate from age ( when

user only enter age ) .

It is : todayCalendar.add( Calendar.YEAR, -1 * age );

What Abyot did is

      todayCalendar.set( Calendar.DATE, 1 );
      todayCalendar.set( Calendar.MONTH, Calendar.JANUARY );
      todayCalendar.add( Calendar.YEAR, -1 * age );

Because we generate the id base on birthdate , get current date should be

better.

Hope this is ok for Abyot…

Each country will have different formats…so I think for current we just

can change code when implementing in the country. Building a module for this

would take time…

Finally, but almost those things only follow India 's requirements.

Please give comment then we can try to make it more generic…

Regards,

Viet Nguyen


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

Hi John

Hi bob,
the system generated ID is to one way to identify the case or person. using
orgunit you mean the code for that organization unit. In india they have
generated a 16 digit ID based on Country, Province,District,Sub-district and
facility. but the problem with this is what happen if new district
or province is created. In norway the personal id number is
ddmmyy+sex+random number. I thougth we cloud use the same but increasing the
random number to avoid the duplicate.

I think this is a national id number. In Norway they do indeed use
the national ID number as a patient ID. And, believe it or not,
Norway does not follow best practice in this area. They do it
probably because it was convenient and they started doing it at a time
before anyone really took much time to think about it. The hazard of
early adoption in the information age. They are not the only country
which now finds itself in this position.

I've mentioned a few times on this list that national identifiers are
not always suitable for use as patient identifiers. That they are
frequently coerced for this use is now broadly understood to be a
common but bad practice, largely because the requirements of national
ids are not generally the same as requirements for patient ids. There
are a lot of references out there on what these requirements are - I
think myself and Saptarshi have provided some links to literature on
the subject. Just googled this one fresh for example
(The Future of Identity in the Information Society: 4th IFIP WG 9.2, 9.6, 11 ... - Google Books)
coz it mentions Norway - what a horrible url - and not a great
article. You can I'm sure access better quality stuff through the
university.

In the case of India, where they are now designing a national ID from
scratch, they might have taken this issue into account - ie they have
the benefit of hindsight that the identifier might (read it always
happens!) be used for many purposes beyond what may have been its
original intent. So the ID could be useful if encoded on a card or
something, but the downside being that very few people are going to
memorize it if it has many random digits. Alphanumerics can help keep
it shorter.

I'm not sure if I get your concern about provinces and districts
changing etc. Using a similar scheme but based on facility+unique
string a patient would only really need to commit to memory the unique
string part in 95% of cases. She would only need the full number with
prefix part when visiting a different facility at which point it would
be useful to have the full number on a card, file or what have you.
But even then, if she remembered the facility that she got it from, it
could be reasonably reconstructed.

I can sympathize with the desire for simplicity and I think we should
strive for a simple solution. But given that is widely accepted that
encoding the birthdate and gender in a patient id is a bad practice I
don't think it is wise to roll-out a new personal identification
system like this. To me it might indicate a certain amateurism and
lack of familiarity with the literature which could reflect badly on
the project. Particularly as you are undergoing your security review.
I also do know that the openmrs guys have really put a lot of thought
into this.

So my warning would be if you go ahead with birthdates and gender you
should be prepared to be hammered from all sides.

Cheers
Bob

···

On 3 March 2010 15:20, John lewis <johnlewis.hisp@gmail.com> wrote:

And its also useful that the person
dont have to remember all the 16 or 14 digit number. for the sake of
simplicity we used this method.
John

On Wed, Mar 3, 2010 at 1:35 PM, Bob Jolliffe <bobjolliffe@gmail.com> wrote:

Hi

On 3 March 2010 12:20, Viet Nguyen <phamquocviet@gmail.com> wrote:
>
> Hi,
>
> Just a quick update about Patient registration form functionality :
>
> * Check duplicate :
>
> This function allow user to check for existing patient base on : name ,
> birthdate, age, gender
>
> If there is duplicate patient, a pop up will be showed, with the list of
> all
> the duplicated patients.
>
> From this pop up, user can have two options :
>
> Continue create the current patient. So there will be two patients with
> the
> same information like above. But their identifiers must be different
> which
> will be checked later.
> User can choose a patient from the list duplicated patient to update
> information for him, by click on the button "Update this patient" that
> follow by each patient in the list. User will then be redirected to the
> Update Patient page.
>
> * Under age patient :
>
> Under age patient can be understand as a child. The purpose of this
> field is
> not to hard code the age to define a child, like age < 5 or age < 15.
>
> In the registration form, there is a check box named " Is Underage" .
> User
> check on this check box to identify the patient is a child. A pop up
> will
> be showed after clicking.
>
> The purpose of this pop up is : user must choose a representative for
> this
> child. Because , some identifiers that are mandatory ( can be defined
> in
> Patient Identifier Type management page ) . But a child can not have
> those
> identifier, so we have to inherit those identifier from the child's
> representative.
>
> Not all identifier can be inherited, you can defined a
> PatientIdentiferType
> is able to inherit or not when creating it. The field name is
> "Related"
> ... ( God ...why didn't I use" Inheritable" .... ) .
>
> If a PatientIdentifierType with "related" = FALSE and "mandatory" = TRUE
> then user must enter value for it.
>
> Ok, back to the popup, there are two tabs :
>
> Search existing person : user can search for an existing patient in
> system
> to be the representative of the child.
> Add new person : said this is person, because this is not really a
> patient,
> this person is just giving identifier...not enrolling to any program, at
> least at this step. Of course the record is also saved to the patient
> table.
> The form just only include basic information ( name , birthdate,
> gender.. )
> and Identifiers. No attributes is needed. Of course user can update
> attributes for this person later by the Update Patient page.
>
> One problem in this function that I can not have enough time to do :
>
> In the combo box Relationship Type, there should be Parent and Guardian,
> I
> hard coded this. You should create two relationship type with this
> information before testing this function :
>
> A is to B : Guardian, B is to A : Child
> A is to B : Parent , B is to A : Child.
>
> The list of relationship type should be get from the Relationship type
> table. But if we put everything to the combo box, then user may choose
> Husband, Wife, or even child...which is so wrong.
>
> My plan is creating an object RelationshipGroup, which should be based
> on
> the age...
>
> Anyway, because we are late for releasing this version in India. so hard
> code for now is the only solution. I will continue working on this, so
> ...please don't worry...
>
> * System generated identifier :
>
> I looked at the id_gen module from OpenMRS. Well , they have a whole
> module
> for this which has many functionality for manage system auto generated
> identifier.
>
> I can not have enough time for getting all of that. So what I did is
> just
> get a piece of code that is used for generate a check digit for the ID.
>
> The format that Indian team chose is :
> [BirthDate][Gender][XXXXXX][checkdigit]

Encoding the birthdate and gender into a patient identifier is
considered bad practice. Using the orgunit+random digits would be
much better. It shouldn't matter if the patient "migrates". The
number was simply issued by a particular facility.

Regards
Bob

>
> BirthDate : yyyyMMdd
> Gender : Male = 1 ; Female = 0
> XXXXXX : a random number with length = 6 ( 0 - 999999 )
> checkdigit : generated using Luhn Algorithm ( thanks to OpenMRS guys )
>
> I also changed the way that Abyot generate the birthdate from age ( when
> user only enter age ) .
> It is : todayCalendar.add( Calendar.YEAR, -1 * age );
> What Abyot did is
> todayCalendar.set( Calendar.DATE, 1 );
> todayCalendar.set( Calendar.MONTH, Calendar.JANUARY );
> todayCalendar.add( Calendar.YEAR, -1 * age );
> Because we generate the id base on birthdate , get current date should
> be
> better.
> Hope this is ok for Abyot....
>
> Each country will have different formats...so I think for current we
> just
> can change code when implementing in the country. Building a module for
> this
> would take time....
>
> Finally, but almost those things only follow India 's requirements.
> Please give comment then we can try to make it more generic...
>
> Regards,
>
> Viet Nguyen
>
>

_______________________________________________
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

Ok bob, point taken. when you say facility+ unique string what do you mean. facility code or name of the facility and unique string is random number right?

···

On Wed, Mar 3, 2010 at 6:11 PM, Bob Jolliffe bobjolliffe@gmail.com wrote:

Hi John

On 3 March 2010 15:20, John lewis johnlewis.hisp@gmail.com wrote:

Hi bob,

the system generated ID is to one way to identify the case or person. using

orgunit you mean the code for that organization unit. In india they have

generated a 16 digit ID based on Country, Province,District,Sub-district and

facility. but the problem with this is what happen if new district

or province is created. In norway the personal id number is

ddmmyy+sex+random number. I thougth we cloud use the same but increasing the

random number to avoid the duplicate.

I think this is a national id number. In Norway they do indeed use

the national ID number as a patient ID. And, believe it or not,

Norway does not follow best practice in this area. They do it

probably because it was convenient and they started doing it at a time

before anyone really took much time to think about it. The hazard of

early adoption in the information age. They are not the only country

which now finds itself in this position.

I’ve mentioned a few times on this list that national identifiers are

not always suitable for use as patient identifiers. That they are

frequently coerced for this use is now broadly understood to be a

common but bad practice, largely because the requirements of national

ids are not generally the same as requirements for patient ids. There

are a lot of references out there on what these requirements are - I

think myself and Saptarshi have provided some links to literature on

the subject. Just googled this one fresh for example

(http://books.google.com/books?id=X0JeKx8-J0cC&pg=PA59&lpg=PA59&dq=norway+patient+identifier&source=bl&ots=6C8eZlwxLb&sig=zTY4mpmxpNtvGGz-hssv3KVEQh8&hl=en&ei=F46OS7KHEJO7jAfZocDpAw&sa=X&oi=book_result&ct=result&resnum=5&ved=0CB8Q6AEwBA)

coz it mentions Norway - what a horrible url - and not a great

article. You can I’m sure access better quality stuff through the

university.

In the case of India, where they are now designing a national ID from

scratch, they might have taken this issue into account - ie they have

the benefit of hindsight that the identifier might (read it always

happens!) be used for many purposes beyond what may have been its

original intent. So the ID could be useful if encoded on a card or

something, but the downside being that very few people are going to

memorize it if it has many random digits. Alphanumerics can help keep

it shorter.

I’m not sure if I get your concern about provinces and districts

changing etc. Using a similar scheme but based on facility+unique

string a patient would only really need to commit to memory the unique

string part in 95% of cases. She would only need the full number with

prefix part when visiting a different facility at which point it would

be useful to have the full number on a card, file or what have you.

But even then, if she remembered the facility that she got it from, it

could be reasonably reconstructed.

I can sympathize with the desire for simplicity and I think we should

strive for a simple solution. But given that is widely accepted that

encoding the birthdate and gender in a patient id is a bad practice I

don’t think it is wise to roll-out a new personal identification

system like this. To me it might indicate a certain amateurism and

lack of familiarity with the literature which could reflect badly on

the project. Particularly as you are undergoing your security review.

I also do know that the openmrs guys have really put a lot of thought

into this.

So my warning would be if you go ahead with birthdates and gender you

should be prepared to be hammered from all sides.

Cheers

Bob

And its also useful that the person

dont have to remember all the 16 or 14 digit number. for the sake of

simplicity we used this method.

John

On Wed, Mar 3, 2010 at 1:35 PM, Bob Jolliffe bobjolliffe@gmail.com wrote:

Hi

On 3 March 2010 12:20, Viet Nguyen phamquocviet@gmail.com wrote:

Hi,

Just a quick update about Patient registration form functionality :

  • Check duplicate :

This function allow user to check for existing patient base on : name ,

birthdate, age, gender

If there is duplicate patient, a pop up will be showed, with the list of

all

the duplicated patients.

From this pop up, user can have two options :

Continue create the current patient. So there will be two patients with

the

same information like above. But their identifiers must be different

which

will be checked later.

User can choose a patient from the list duplicated patient to update

information for him, by click on the button “Update this patient” that

follow by each patient in the list. User will then be redirected to the

Update Patient page.

  • Under age patient :

Under age patient can be understand as a child. The purpose of this

field is

not to hard code the age to define a child, like age < 5 or age < 15.

In the registration form, there is a check box named " Is Underage" .

User

check on this check box to identify the patient is a child. A pop up

will

be showed after clicking.

The purpose of this pop up is : user must choose a representative for

this

child. Because , some identifiers that are mandatory ( can be defined

in

Patient Identifier Type management page ) . But a child can not have

those

identifier, so we have to inherit those identifier from the child’s

representative.

Not all identifier can be inherited, you can defined a

PatientIdentiferType

is able to inherit or not when creating it. The field name is

“Related”

… ( God …why didn’t I use" Inheritable" … ) .

If a PatientIdentifierType with “related” = FALSE and “mandatory” = TRUE

then user must enter value for it.

Ok, back to the popup, there are two tabs :

Search existing person : user can search for an existing patient in

system

to be the representative of the child.

Add new person : said this is person, because this is not really a

patient,

this person is just giving identifier…not enrolling to any program, at

least at this step. Of course the record is also saved to the patient

table.

The form just only include basic information ( name , birthdate,

gender… )

and Identifiers. No attributes is needed. Of course user can update

attributes for this person later by the Update Patient page.

One problem in this function that I can not have enough time to do :

In the combo box Relationship Type, there should be Parent and Guardian,

I

hard coded this. You should create two relationship type with this

information before testing this function :

A is to B : Guardian, B is to A : Child

A is to B : Parent , B is to A : Child.

The list of relationship type should be get from the Relationship type

table. But if we put everything to the combo box, then user may choose

Husband, Wife, or even child…which is so wrong.

My plan is creating an object RelationshipGroup, which should be based

on

the age…

Anyway, because we are late for releasing this version in India. so hard

code for now is the only solution. I will continue working on this, so

…please don’t worry…

  • System generated identifier :

I looked at the id_gen module from OpenMRS. Well , they have a whole

module

for this which has many functionality for manage system auto generated

identifier.

I can not have enough time for getting all of that. So what I did is

just

get a piece of code that is used for generate a check digit for the ID.

The format that Indian team chose is :

[BirthDate][Gender][XXXXXX][checkdigit]

Encoding the birthdate and gender into a patient identifier is

considered bad practice. Using the orgunit+random digits would be

much better. It shouldn’t matter if the patient “migrates”. The

number was simply issued by a particular facility.

Regards

Bob

BirthDate : yyyyMMdd

Gender : Male = 1 ; Female = 0

XXXXXX : a random number with length = 6 ( 0 - 999999 )

checkdigit : generated using Luhn Algorithm ( thanks to OpenMRS guys )

I also changed the way that Abyot generate the birthdate from age ( when

user only enter age ) .

It is : todayCalendar.add( Calendar.YEAR, -1 * age );

What Abyot did is

      todayCalendar.set( Calendar.DATE, 1 );
      todayCalendar.set( Calendar.MONTH, Calendar.JANUARY );
      todayCalendar.add( Calendar.YEAR, -1 * age );

Because we generate the id base on birthdate , get current date should

be

better.

Hope this is ok for Abyot…

Each country will have different formats…so I think for current we

just

can change code when implementing in the country. Building a module for

this

would take time…

Finally, but almost those things only follow India 's requirements.

Please give comment then we can try to make it more generic…

Regards,

Viet Nguyen


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

Ok bob, point taken. when you say facility+ unique string what do you mean.
facility code or name of the facility and unique string is random number
right?

yup. and facility code is infinitely better than facility name.
Though its obviously useful for the patient to know the name.

···

On 3 March 2010 17:23, John lewis <johnlewis.hisp@gmail.com> wrote:

On Wed, Mar 3, 2010 at 6:11 PM, Bob Jolliffe <bobjolliffe@gmail.com> wrote:

Hi John

On 3 March 2010 15:20, John lewis <johnlewis.hisp@gmail.com> wrote:
> Hi bob,
> the system generated ID is to one way to identify the case or person.
> using
> orgunit you mean the code for that organization unit. In india they have
> generated a 16 digit ID based on Country, Province,District,Sub-district
> and
> facility. but the problem with this is what happen if new district
> or province is created. In norway the personal id number is
> ddmmyy+sex+random number. I thougth we cloud use the same but increasing
> the
> random number to avoid the duplicate.

I think this is a national id number. In Norway they do indeed use
the national ID number as a patient ID. And, believe it or not,
Norway does not follow best practice in this area. They do it
probably because it was convenient and they started doing it at a time
before anyone really took much time to think about it. The hazard of
early adoption in the information age. They are not the only country
which now finds itself in this position.

I've mentioned a few times on this list that national identifiers are
not always suitable for use as patient identifiers. That they are
frequently coerced for this use is now broadly understood to be a
common but bad practice, largely because the requirements of national
ids are not generally the same as requirements for patient ids. There
are a lot of references out there on what these requirements are - I
think myself and Saptarshi have provided some links to literature on
the subject. Just googled this one fresh for example

(The Future of Identity in the Information Society: 4th IFIP WG 9.2, 9.6, 11 ... - Google Books)
coz it mentions Norway - what a horrible url - and not a great
article. You can I'm sure access better quality stuff through the
university.

In the case of India, where they are now designing a national ID from
scratch, they might have taken this issue into account - ie they have
the benefit of hindsight that the identifier might (read it always
happens!) be used for many purposes beyond what may have been its
original intent. So the ID could be useful if encoded on a card or
something, but the downside being that very few people are going to
memorize it if it has many random digits. Alphanumerics can help keep
it shorter.

I'm not sure if I get your concern about provinces and districts
changing etc. Using a similar scheme but based on facility+unique
string a patient would only really need to commit to memory the unique
string part in 95% of cases. She would only need the full number with
prefix part when visiting a different facility at which point it would
be useful to have the full number on a card, file or what have you.
But even then, if she remembered the facility that she got it from, it
could be reasonably reconstructed.

I can sympathize with the desire for simplicity and I think we should
strive for a simple solution. But given that is widely accepted that
encoding the birthdate and gender in a patient id is a bad practice I
don't think it is wise to roll-out a new personal identification
system like this. To me it might indicate a certain amateurism and
lack of familiarity with the literature which could reflect badly on
the project. Particularly as you are undergoing your security review.
I also do know that the openmrs guys have really put a lot of thought
into this.

So my warning would be if you go ahead with birthdates and gender you
should be prepared to be hammered from all sides.

Cheers
Bob

>And its also useful that the person
> dont have to remember all the 16 or 14 digit number. for the sake of
> simplicity we used this method.
> John
>
> On Wed, Mar 3, 2010 at 1:35 PM, Bob Jolliffe <bobjolliffe@gmail.com> >> > wrote:
>>
>> Hi
>>
>> On 3 March 2010 12:20, Viet Nguyen <phamquocviet@gmail.com> wrote:
>> >
>> > Hi,
>> >
>> > Just a quick update about Patient registration form functionality :
>> >
>> > * Check duplicate :
>> >
>> > This function allow user to check for existing patient base on : name
>> > ,
>> > birthdate, age, gender
>> >
>> > If there is duplicate patient, a pop up will be showed, with the list
>> > of
>> > all
>> > the duplicated patients.
>> >
>> > From this pop up, user can have two options :
>> >
>> > Continue create the current patient. So there will be two patients
>> > with
>> > the
>> > same information like above. But their identifiers must be different
>> > which
>> > will be checked later.
>> > User can choose a patient from the list duplicated patient to update
>> > information for him, by click on the button "Update this patient"
>> > that
>> > follow by each patient in the list. User will then be redirected to
>> > the
>> > Update Patient page.
>> >
>> > * Under age patient :
>> >
>> > Under age patient can be understand as a child. The purpose of this
>> > field is
>> > not to hard code the age to define a child, like age < 5 or age <
>> > 15.
>> >
>> > In the registration form, there is a check box named " Is Underage" .
>> > User
>> > check on this check box to identify the patient is a child. A pop up
>> > will
>> > be showed after clicking.
>> >
>> > The purpose of this pop up is : user must choose a representative
>> > for
>> > this
>> > child. Because , some identifiers that are mandatory ( can be
>> > defined
>> > in
>> > Patient Identifier Type management page ) . But a child can not have
>> > those
>> > identifier, so we have to inherit those identifier from the child's
>> > representative.
>> >
>> > Not all identifier can be inherited, you can defined a
>> > PatientIdentiferType
>> > is able to inherit or not when creating it. The field name is
>> > "Related"
>> > ... ( God ...why didn't I use" Inheritable" .... ) .
>> >
>> > If a PatientIdentifierType with "related" = FALSE and "mandatory" =
>> > TRUE
>> > then user must enter value for it.
>> >
>> > Ok, back to the popup, there are two tabs :
>> >
>> > Search existing person : user can search for an existing patient in
>> > system
>> > to be the representative of the child.
>> > Add new person : said this is person, because this is not really a
>> > patient,
>> > this person is just giving identifier...not enrolling to any program,
>> > at
>> > least at this step. Of course the record is also saved to the patient
>> > table.
>> > The form just only include basic information ( name , birthdate,
>> > gender.. )
>> > and Identifiers. No attributes is needed. Of course user can update
>> > attributes for this person later by the Update Patient page.
>> >
>> > One problem in this function that I can not have enough time to do :
>> >
>> > In the combo box Relationship Type, there should be Parent and
>> > Guardian,
>> > I
>> > hard coded this. You should create two relationship type with this
>> > information before testing this function :
>> >
>> > A is to B : Guardian, B is to A : Child
>> > A is to B : Parent , B is to A : Child.
>> >
>> > The list of relationship type should be get from the Relationship
>> > type
>> > table. But if we put everything to the combo box, then user may
>> > choose
>> > Husband, Wife, or even child...which is so wrong.
>> >
>> > My plan is creating an object RelationshipGroup, which should be
>> > based
>> > on
>> > the age...
>> >
>> > Anyway, because we are late for releasing this version in India. so
>> > hard
>> > code for now is the only solution. I will continue working on this,
>> > so
>> > ...please don't worry...
>> >
>> > * System generated identifier :
>> >
>> > I looked at the id_gen module from OpenMRS. Well , they have a whole
>> > module
>> > for this which has many functionality for manage system auto
>> > generated
>> > identifier.
>> >
>> > I can not have enough time for getting all of that. So what I did is
>> > just
>> > get a piece of code that is used for generate a check digit for the
>> > ID.
>> >
>> > The format that Indian team chose is :
>> > [BirthDate][Gender][XXXXXX][checkdigit]
>>
>> Encoding the birthdate and gender into a patient identifier is
>> considered bad practice. Using the orgunit+random digits would be
>> much better. It shouldn't matter if the patient "migrates". The
>> number was simply issued by a particular facility.
>>
>> Regards
>> Bob
>>
>> >
>> > BirthDate : yyyyMMdd
>> > Gender : Male = 1 ; Female = 0
>> > XXXXXX : a random number with length = 6 ( 0 - 999999 )
>> > checkdigit : generated using Luhn Algorithm ( thanks to OpenMRS guys
>> > )
>> >
>> > I also changed the way that Abyot generate the birthdate from age (
>> > when
>> > user only enter age ) .
>> > It is : todayCalendar.add( Calendar.YEAR, -1 * age );
>> > What Abyot did is
>> > todayCalendar.set( Calendar.DATE, 1 );
>> > todayCalendar.set( Calendar.MONTH, Calendar.JANUARY );
>> > todayCalendar.add( Calendar.YEAR, -1 * age );
>> > Because we generate the id base on birthdate , get current date
>> > should
>> > be
>> > better.
>> > Hope this is ok for Abyot....
>> >
>> > Each country will have different formats...so I think for current we
>> > just
>> > can change code when implementing in the country. Building a module
>> > for
>> > this
>> > would take time....
>> >
>> > Finally, but almost those things only follow India 's requirements.
>> > Please give comment then we can try to make it more generic...
>> >
>> > Regards,
>> >
>> > Viet Nguyen
>> >
>> >
>>
>> _______________________________________________
>> 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
>
>

Hi Viet,

Thanks for the update. But a little afraid that you are making it very much hard coded to the requirements of India.

Any change you are making is fine with me as long as it makes sense to broader use cases. The ID for example is better if we could keep it as it was before. I remember the ID was made of organization unit code or short name plus a 5 (or 6??) digit number. It was made like this on the assumption that each registering unit will be a facility to serve a population of hundred thousand and remember that our assumption is this system is going to be used by the lowest possible health administrative units (at least as far as registration is concerned). And whenever a migration occurs we have to update the person’s ID. We should only keep the UUID unique, unchanged and one-to-one. So the patient ID should be somewhat floating — it could also be possible for a person to have more than one identifier.

Calculating birth date from a given age - yes you will have conflicts if all ages are calculated relative to the first of January (that is how it is currently). But then your new approach makes sense if everyone if telling age relative to the current date.

And the relationship type - instead of assuming there will always be parent/guardian vs child relationship, why don’t you provide users with the list of available relationships so that they can choose ?

Thank you

Abyot.

···

On Wed, Mar 3, 2010 at 1:20 PM, Viet Nguyen phamquocviet@gmail.com wrote:

Hi,

Just a quick update about Patient registration form functionality :

* Check duplicate :

This function allow user to check for existing patient base on : name , birthdate, age, gender

If there is duplicate patient, a pop up will be showed, with the list of all the duplicated patients.

From this pop up, user can have two options :

  1. Continue create the current patient. So there will be two patients with the same information like above. But their identifiers must be different which will be checked later.
  2. User can choose a patient from the list duplicated patient to update information for him, by click on the button “Update this patient” that follow by each patient in the list. User will then be redirected to the Update Patient page.
    * Under age patient :

Under age patient can be understand as a child. The purpose of this field is not to hard code the age to define a child, like age < 5 or age < 15.

In the registration form, there is a check box named " Is Underage" . User check on this check box to identify the patient is a child. A pop up will be showed after clicking.

The purpose of this pop up is : user must choose a representative for this child. Because , some identifiers that are mandatory ( can be defined in Patient Identifier Type management page ) . But a child can not have those identifier, so we have to inherit those identifier from the child’s representative.

Not all identifier can be inherited, you can defined a PatientIdentiferType is able to inherit or not when creating it. The field name is “Related” … ( God …why didn’t I use" Inheritable" … ) .

If a PatientIdentifierType with “related” = FALSE and “mandatory” = TRUE then user must enter value for it.

Ok, back to the popup, there are two tabs :

  1. Search existing person : user can search for an existing patient in system to be the representative of the child.
  2. Add new person : said this is person, because this is not really a patient, this person is just giving identifier…not enrolling to any program, at least at this step. Of course the record is also saved to the patient table. The form just only include basic information ( name , birthdate, gender… ) and Identifiers. No attributes is needed. Of course user can update attributes for this person later by the Update Patient page.
    One problem in this function that I can not have enough time to do :

In the combo box Relationship Type, there should be Parent and Guardian, I hard coded this. You should create two relationship type with this information before testing this function :

A is to B : Guardian, B is to A : Child
A is to B : Parent , B is to A : Child.

The list of relationship type should be get from the Relationship type table. But if we put everything to the combo box, then user may choose Husband, Wife, or even child…which is so wrong.

My plan is creating an object RelationshipGroup, which should be based on the age…

Anyway, because we are late for releasing this version in India. so hard code for now is the only solution. I will continue working on this, so …please don’t worry…

* System generated identifier :

I looked at the id_gen module from OpenMRS. Well , they have a whole module for this which has many functionality for manage system auto generated identifier.

I can not have enough time for getting all of that. So what I did is just get a piece of code that is used for generate a check digit for the ID.

The format that Indian team chose is : [BirthDate][Gender][XXXXXX][checkdigit]

BirthDate : yyyyMMdd
Gender : Male = 1 ; Female = 0
XXXXXX : a random number with length = 6 ( 0 - 999999 )
checkdigit : generated using Luhn Algorithm ( thanks to OpenMRS guys )

I also changed the way that Abyot generate the birthdate from age ( when user only enter age ) .
It is : todayCalendar.add( Calendar.YEAR, -1 * age );
What Abyot did is
todayCalendar.set( Calendar.DATE, 1 );

      todayCalendar.set( Calendar.MONTH, Calendar.JANUARY );
      todayCalendar.add( Calendar.YEAR, -1 * age );

Because we generate the id base on birthdate , get current date should be better.
Hope this is ok for Abyot…

Each country will have different formats…so I think for current we just can change code when implementing in the country. Building a module for this would take time…

Finally, but almost those things only follow India 's requirements.

Please give comment then we can try to make it more generic…

Regards,

Viet Nguyen


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

Hi John

Hi bob,

the system generated ID is to one way to identify the case or person. using

orgunit you mean the code for that organization unit. In india they have

generated a 16 digit ID based on Country, Province,District,Sub-district and

facility. but the problem with this is what happen if new district

or province is created. In norway the personal id number is

ddmmyy+sex+random number. I thougth we cloud use the same but increasing the

random number to avoid the duplicate.

I think this is a national id number. In Norway they do indeed use

the national ID number as a patient ID. And, believe it or not,

Norway does not follow best practice in this area. They do it

probably because it was convenient and they started doing it at a time

before anyone really took much time to think about it. The hazard of

early adoption in the information age. They are not the only country

which now finds itself in this position.

I’ve mentioned a few times on this list that national identifiers are

not always suitable for use as patient identifiers. That they are

frequently coerced for this use is now broadly understood to be a

common but bad practice, largely because the requirements of national

ids are not generally the same as requirements for patient ids. There

are a lot of references out there on what these requirements are - I

think myself and Saptarshi have provided some links to literature on

the subject. Just googled this one fresh for example

(http://books.google.com/books?id=X0JeKx8-J0cC&pg=PA59&lpg=PA59&dq=norway+patient+identifier&source=bl&ots=6C8eZlwxLb&sig=zTY4mpmxpNtvGGz-hssv3KVEQh8&hl=en&ei=F46OS7KHEJO7jAfZocDpAw&sa=X&oi=book_result&ct=result&resnum=5&ved=0CB8Q6AEwBA)

coz it mentions Norway - what a horrible url - and not a great

article. You can I’m sure access better quality stuff through the

university.

In the case of India, where they are now designing a national ID from

scratch, they might have taken this issue into account - ie they have

the benefit of hindsight that the identifier might (read it always

happens!) be used for many purposes beyond what may have been its

original intent. So the ID could be useful if encoded on a card or

something, but the downside being that very few people are going to

memorize it if it has many random digits. Alphanumerics can help keep

it shorter.

I’m not sure if I get your concern about provinces and districts

changing etc. Using a similar scheme but based on facility+unique

string a patient would only really need to commit to memory the unique

string part in 95% of cases. She would only need the full number with

prefix part when visiting a different facility at which point it would

be useful to have the full number on a card, file or what have you.

But even then, if she remembered the facility that she got it from, it

could be reasonably reconstructed.

I can sympathize with the desire for simplicity and I think we should

strive for a simple solution. But given that is widely accepted that

encoding the birthdate and gender in a patient id is a bad practice I

don’t think it is wise to roll-out a new personal identification

system like this. To me it might indicate a certain amateurism and

lack of familiarity with the literature which could reflect badly on

the project. Particularly as you are undergoing your security review.

I also do know that the openmrs guys have really put a lot of thought

into this.

So my warning would be if you go ahead with birthdates and gender you

should be prepared to be hammered from all sides.

Cheers

Bob

I think we can take a look at here http://en.wikipedia.org/wiki/National_identification_number to see how countries in the world dealing with this problem. While putting birthdate in the ID is considered as a violence of privacy, most of countries use it in their national ID systems. They might do thing wrong? ID system, as I perceive, is very similar to a infrastructure with its installed based. Addressing it is not the problem of good or bad but what the current situation is and how to build upon that, I think.

Thanh

···

On Thu, Mar 4, 2010 at 12:11 AM, Bob Jolliffe bobjolliffe@gmail.com wrote:

On 3 March 2010 15:20, John lewis johnlewis.hisp@gmail.com wrote:

And its also useful that the person

dont have to remember all the 16 or 14 digit number. for the sake of

simplicity we used this method.

John

On Wed, Mar 3, 2010 at 1:35 PM, Bob Jolliffe bobjolliffe@gmail.com wrote:

Hi

On 3 March 2010 12:20, Viet Nguyen phamquocviet@gmail.com wrote:

Hi,

Just a quick update about Patient registration form functionality :

  • Check duplicate :

This function allow user to check for existing patient base on : name ,

birthdate, age, gender

If there is duplicate patient, a pop up will be showed, with the list of

all

the duplicated patients.

From this pop up, user can have two options :

Continue create the current patient. So there will be two patients with

the

same information like above. But their identifiers must be different

which

will be checked later.

User can choose a patient from the list duplicated patient to update

information for him, by click on the button “Update this patient” that

follow by each patient in the list. User will then be redirected to the

Update Patient page.

  • Under age patient :

Under age patient can be understand as a child. The purpose of this

field is

not to hard code the age to define a child, like age < 5 or age < 15.

In the registration form, there is a check box named " Is Underage" .

User

check on this check box to identify the patient is a child. A pop up

will

be showed after clicking.

The purpose of this pop up is : user must choose a representative for

this

child. Because , some identifiers that are mandatory ( can be defined

in

Patient Identifier Type management page ) . But a child can not have

those

identifier, so we have to inherit those identifier from the child’s

representative.

Not all identifier can be inherited, you can defined a

PatientIdentiferType

is able to inherit or not when creating it. The field name is

“Related”

… ( God …why didn’t I use" Inheritable" … ) .

If a PatientIdentifierType with “related” = FALSE and “mandatory” = TRUE

then user must enter value for it.

Ok, back to the popup, there are two tabs :

Search existing person : user can search for an existing patient in

system

to be the representative of the child.

Add new person : said this is person, because this is not really a

patient,

this person is just giving identifier…not enrolling to any program, at

least at this step. Of course the record is also saved to the patient

table.

The form just only include basic information ( name , birthdate,

gender… )

and Identifiers. No attributes is needed. Of course user can update

attributes for this person later by the Update Patient page.

One problem in this function that I can not have enough time to do :

In the combo box Relationship Type, there should be Parent and Guardian,

I

hard coded this. You should create two relationship type with this

information before testing this function :

A is to B : Guardian, B is to A : Child

A is to B : Parent , B is to A : Child.

The list of relationship type should be get from the Relationship type

table. But if we put everything to the combo box, then user may choose

Husband, Wife, or even child…which is so wrong.

My plan is creating an object RelationshipGroup, which should be based

on

the age…

Anyway, because we are late for releasing this version in India. so hard

code for now is the only solution. I will continue working on this, so

…please don’t worry…

  • System generated identifier :

I looked at the id_gen module from OpenMRS. Well , they have a whole

module

for this which has many functionality for manage system auto generated

identifier.

I can not have enough time for getting all of that. So what I did is

just

get a piece of code that is used for generate a check digit for the ID.

The format that Indian team chose is :

[BirthDate][Gender][XXXXXX][checkdigit]

Encoding the birthdate and gender into a patient identifier is

considered bad practice. Using the orgunit+random digits would be

much better. It shouldn’t matter if the patient “migrates”. The

number was simply issued by a particular facility.

Regards

Bob

BirthDate : yyyyMMdd

Gender : Male = 1 ; Female = 0

XXXXXX : a random number with length = 6 ( 0 - 999999 )

checkdigit : generated using Luhn Algorithm ( thanks to OpenMRS guys )

I also changed the way that Abyot generate the birthdate from age ( when

user only enter age ) .

It is : todayCalendar.add( Calendar.YEAR, -1 * age );

What Abyot did is

      todayCalendar.set( Calendar.DATE, 1 );
      todayCalendar.set( Calendar.MONTH, Calendar.JANUARY );
      todayCalendar.add( Calendar.YEAR, -1 * age );

Because we generate the id base on birthdate , get current date should

be

better.

Hope this is ok for Abyot…

Each country will have different formats…so I think for current we

just

can change code when implementing in the country. Building a module for

this

would take time…

Finally, but almost those things only follow India 's requirements.

Please give comment then we can try to make it more generic…

Regards,

Viet Nguyen


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


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


Best regards,
Thanh


Center for HIS development
957, 3/2 st., Dist 11, Hochiminh city
Tel: 08-956 0150
Cell: 098 221 8623


Hi Thanh

Hi John

> Hi bob,
> the system generated ID is to one way to identify the case or person.
> using
> orgunit you mean the code for that organization unit. In india they have
> generated a 16 digit ID based on Country, Province,District,Sub-district
> and
> facility. but the problem with this is what happen if new district
> or province is created. In norway the personal id number is
> ddmmyy+sex+random number. I thougth we cloud use the same but increasing
> the
> random number to avoid the duplicate.

I think this is a national id number. In Norway they do indeed use
the national ID number as a patient ID. And, believe it or not,
Norway does not follow best practice in this area. They do it
probably because it was convenient and they started doing it at a time
before anyone really took much time to think about it. The hazard of
early adoption in the information age. They are not the only country
which now finds itself in this position.

I've mentioned a few times on this list that national identifiers are
not always suitable for use as patient identifiers. That they are
frequently coerced for this use is now broadly understood to be a
common but bad practice, largely because the requirements of national
ids are not generally the same as requirements for patient ids. There
are a lot of references out there on what these requirements are - I
think myself and Saptarshi have provided some links to literature on
the subject. Just googled this one fresh for example

(The Future of Identity in the Information Society: 4th IFIP WG 9.2, 9.6, 11 ... - Google Books)
coz it mentions Norway - what a horrible url - and not a great
article. You can I'm sure access better quality stuff through the
university.

In the case of India, where they are now designing a national ID from
scratch, they might have taken this issue into account - ie they have
the benefit of hindsight that the identifier might (read it always
happens!) be used for many purposes beyond what may have been its
original intent. So the ID could be useful if encoded on a card or
something, but the downside being that very few people are going to
memorize it if it has many random digits. Alphanumerics can help keep
it shorter.

I'm not sure if I get your concern about provinces and districts
changing etc. Using a similar scheme but based on facility+unique
string a patient would only really need to commit to memory the unique
string part in 95% of cases. She would only need the full number with
prefix part when visiting a different facility at which point it would
be useful to have the full number on a card, file or what have you.
But even then, if she remembered the facility that she got it from, it
could be reasonably reconstructed.

I can sympathize with the desire for simplicity and I think we should
strive for a simple solution. But given that is widely accepted that
encoding the birthdate and gender in a patient id is a bad practice I
don't think it is wise to roll-out a new personal identification
system like this. To me it might indicate a certain amateurism and
lack of familiarity with the literature which could reflect badly on
the project. Particularly as you are undergoing your security review.
I also do know that the openmrs guys have really put a lot of thought
into this.

So my warning would be if you go ahead with birthdates and gender you
should be prepared to be hammered from all sides.

Cheers
Bob

I think we can take a look at here
National identification number - Wikipedia to see how
countries in the world dealing with this problem. While putting birthdate in
the ID is considered as a violence of privacy, most of countries use it in
their national ID systems. They might do thing wrong? ID system, as I
perceive, is very similar to a infrastructure with its installed based.
Addressing it is not the problem of good or bad but what the current
situation is and how to build upon that, I think.

The wikipedia article you refer to deals with national ids. From the
same source re patient identifiers:

Not that I'm in favour of the 28 digit sample. That seems not to be
appropriate where manual systems are the norm. But the desirable
characteristics of a patient identifier are worthwhile being aware of.
Its ok of course to deviate from them with good reason, but lets
start from what is generally considered good practice and work from
there.

Bob

···

On 3 March 2010 19:59, Ngoc Thanh Nguyen <thanh.hispvietnam@gmail.com> wrote:

On Thu, Mar 4, 2010 at 12:11 AM, Bob Jolliffe <bobjolliffe@gmail.com> wrote:

On 3 March 2010 15:20, John lewis <johnlewis.hisp@gmail.com> wrote:

Thanh

>And its also useful that the person
> dont have to remember all the 16 or 14 digit number. for the sake of
> simplicity we used this method.
> John
>
> On Wed, Mar 3, 2010 at 1:35 PM, Bob Jolliffe <bobjolliffe@gmail.com> >> > wrote:
>>
>> Hi
>>
>> On 3 March 2010 12:20, Viet Nguyen <phamquocviet@gmail.com> wrote:
>> >
>> > Hi,
>> >
>> > Just a quick update about Patient registration form functionality :
>> >
>> > * Check duplicate :
>> >
>> > This function allow user to check for existing patient base on : name
>> > ,
>> > birthdate, age, gender
>> >
>> > If there is duplicate patient, a pop up will be showed, with the list
>> > of
>> > all
>> > the duplicated patients.
>> >
>> > From this pop up, user can have two options :
>> >
>> > Continue create the current patient. So there will be two patients
>> > with
>> > the
>> > same information like above. But their identifiers must be different
>> > which
>> > will be checked later.
>> > User can choose a patient from the list duplicated patient to update
>> > information for him, by click on the button "Update this patient"
>> > that
>> > follow by each patient in the list. User will then be redirected to
>> > the
>> > Update Patient page.
>> >
>> > * Under age patient :
>> >
>> > Under age patient can be understand as a child. The purpose of this
>> > field is
>> > not to hard code the age to define a child, like age < 5 or age <
>> > 15.
>> >
>> > In the registration form, there is a check box named " Is Underage" .
>> > User
>> > check on this check box to identify the patient is a child. A pop up
>> > will
>> > be showed after clicking.
>> >
>> > The purpose of this pop up is : user must choose a representative
>> > for
>> > this
>> > child. Because , some identifiers that are mandatory ( can be
>> > defined
>> > in
>> > Patient Identifier Type management page ) . But a child can not have
>> > those
>> > identifier, so we have to inherit those identifier from the child's
>> > representative.
>> >
>> > Not all identifier can be inherited, you can defined a
>> > PatientIdentiferType
>> > is able to inherit or not when creating it. The field name is
>> > "Related"
>> > ... ( God ...why didn't I use" Inheritable" .... ) .
>> >
>> > If a PatientIdentifierType with "related" = FALSE and "mandatory" =
>> > TRUE
>> > then user must enter value for it.
>> >
>> > Ok, back to the popup, there are two tabs :
>> >
>> > Search existing person : user can search for an existing patient in
>> > system
>> > to be the representative of the child.
>> > Add new person : said this is person, because this is not really a
>> > patient,
>> > this person is just giving identifier...not enrolling to any program,
>> > at
>> > least at this step. Of course the record is also saved to the patient
>> > table.
>> > The form just only include basic information ( name , birthdate,
>> > gender.. )
>> > and Identifiers. No attributes is needed. Of course user can update
>> > attributes for this person later by the Update Patient page.
>> >
>> > One problem in this function that I can not have enough time to do :
>> >
>> > In the combo box Relationship Type, there should be Parent and
>> > Guardian,
>> > I
>> > hard coded this. You should create two relationship type with this
>> > information before testing this function :
>> >
>> > A is to B : Guardian, B is to A : Child
>> > A is to B : Parent , B is to A : Child.
>> >
>> > The list of relationship type should be get from the Relationship
>> > type
>> > table. But if we put everything to the combo box, then user may
>> > choose
>> > Husband, Wife, or even child...which is so wrong.
>> >
>> > My plan is creating an object RelationshipGroup, which should be
>> > based
>> > on
>> > the age...
>> >
>> > Anyway, because we are late for releasing this version in India. so
>> > hard
>> > code for now is the only solution. I will continue working on this,
>> > so
>> > ...please don't worry...
>> >
>> > * System generated identifier :
>> >
>> > I looked at the id_gen module from OpenMRS. Well , they have a whole
>> > module
>> > for this which has many functionality for manage system auto
>> > generated
>> > identifier.
>> >
>> > I can not have enough time for getting all of that. So what I did is
>> > just
>> > get a piece of code that is used for generate a check digit for the
>> > ID.
>> >
>> > The format that Indian team chose is :
>> > [BirthDate][Gender][XXXXXX][checkdigit]
>>
>> Encoding the birthdate and gender into a patient identifier is
>> considered bad practice. Using the orgunit+random digits would be
>> much better. It shouldn't matter if the patient "migrates". The
>> number was simply issued by a particular facility.
>>
>> Regards
>> Bob
>>
>> >
>> > BirthDate : yyyyMMdd
>> > Gender : Male = 1 ; Female = 0
>> > XXXXXX : a random number with length = 6 ( 0 - 999999 )
>> > checkdigit : generated using Luhn Algorithm ( thanks to OpenMRS guys
>> > )
>> >
>> > I also changed the way that Abyot generate the birthdate from age (
>> > when
>> > user only enter age ) .
>> > It is : todayCalendar.add( Calendar.YEAR, -1 * age );
>> > What Abyot did is
>> > todayCalendar.set( Calendar.DATE, 1 );
>> > todayCalendar.set( Calendar.MONTH, Calendar.JANUARY );
>> > todayCalendar.add( Calendar.YEAR, -1 * age );
>> > Because we generate the id base on birthdate , get current date
>> > should
>> > be
>> > better.
>> > Hope this is ok for Abyot....
>> >
>> > Each country will have different formats...so I think for current we
>> > just
>> > can change code when implementing in the country. Building a module
>> > for
>> > this
>> > would take time....
>> >
>> > Finally, but almost those things only follow India 's requirements.
>> > Please give comment then we can try to make it more generic...
>> >
>> > Regards,
>> >
>> > Viet Nguyen
>> >
>> >
>>
>> _______________________________________________
>> 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
>
>

_______________________________________________
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

--
Best regards,
Thanh

-------------------
Center for HIS development
957, 3/2 st., Dist 11, Hochiminh city
Tel: 08-956 0150
Cell: 098 221 8623
--------------------

_______________________________________________
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

Been chatting a bit with John and he expressed concern about the orgunit-randomnumber apprach. In India there are multiple installations and one cannot know for sure that an orgunit name will be unique. How do we deal with this?

Using a globally unique identifier could be a solution, but the standard Java implementation (UUID) uses 32 characters and is a bit long. Is implementing our own, shorter one an option?

Lars

I’ve said my take on the solution before… But here again:

We generate a list of 6-digit Base30 ids(2 million or so … ) (…or 8-digit). randomly allocate and make them used. During sync when the ids collide we use the internal uuid to create separate rows and internally we always use a combination id for each row

···

Regards,
Saptarshi PURKAYASTHA
Director R & D, HISP India
Health Information Systems Programme

My Tech Blog: http://sunnytalkstech.blogspot.com

You Live by CHOICE, Not by CHANCE

2010/3/4 Lars Helge Øverland larshelge@gmail.com

Been chatting a bit with John and he expressed concern about the orgunit-randomnumber apprach. In India there are multiple installations and one cannot know for sure that an orgunit name will be unique. How do we deal with this?

Using a globally unique identifier could be a solution, but the standard Java implementation (UUID) uses 32 characters and is a bit long. Is implementing our own, shorter one an option?

Lars


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