Medicare Number Preference

The main identifying number relating to a patient is stored in the database as the Medicare Number. This is the field used for NHS numbers, Medicare numbers and any national ID numbers that relate directly to the patient and will not change over time.

This preference allows the information that is displayed on the front screens within iGene to be formatted correctly. For example, a UK NHS Number is displayed in the 3-3-4 format (e.g. 123 456 7890) but it is stored in the database without any spaces. This is a requirement of all new systems implemented in the NHS.

Similar formatting can be performed on other identifiers if required. The default is to display the items directly as they are stored in the database without any formatting.

The formatting is applied when the data is returned from the database and is not a mask on the field. The user will be able to enter the details in the correct format or without any formatting. When the field is retrieved from the database, the formatting will then be applied.

Patient Search NHS Number Formatted

Location

The Medicare Number Preference is located under the Administration > Preferences area of iGene.

In order to access the preferences area, a user must be a member of a role that has the Administration: Preferences and Administration menu permissions assigned.

  1. Navigate to Administration > Preferences.
  2. Find Medicare Number Preferences in the table and click View by either:
    • Navigating through the Preferences table until the Medicare Number Preferences is found.
    • Performing a search using an existing saved search for Name = Medicare Number Preferences.
    • Performing a search using a newly created search. See the searching guide for information on how to create searches.

Medicare Number Preferences

Configuration

Pressing the View button will display the below form.
Always press Save Settings after making any changes to this form.

Medicare Number Preferences table

Format Medicare Number?

This is the main option. If this is checked then the other items within this area are used. If this is not checked then the medicare number will be displayed as it is stored in the database.

Store Without Spaces?

Using the Store Without Spaces option informs iGene that when it is storing the number to remove any spaces within the string.

Format Pattern

The Format Pattern is a regular expression. It splits the number into groups using the regular expression ready to be displayed. For an NHS number the pattern is:

([0-9]{3})([0-9]{3})([0-9]{4})

The above code example splits the number from the database into three separate items. The code looks for the first value between 0-9 and repeats it three times, the next does the same whilst the 3rd section shows the last 4 numbers. The brackets around each of the [0-9]{3} denote the section.

If a number does not fit this pattern then it will be displayed as it is produced from the database.

Format Replacement

The Format Replacement takes the sections specified in the above format pattern and informs the system how to display them. For an NHS number the expression would be:

$1 $2 $3

The above code takes the first group from the format pattern, then adds a space and does the same for the remaining groups. It would be possible to format a medicare number like this:

($1) $2-$3

The code above would wrap the first group in brackets, add a space and then put a hyphen between groups 2 and 3.

Usage

The Medicare Number preference is used in the following item:

graph LR; A(Medicare Number Preference) B(Patient) A --> |medicareNumber| B

The preference is used on the getMedicareNumber() and setMedicareNumber() fields. If a preference has been configured, iGene will format/read the number using this configuration.