uk-fci / nhs-number

Python package to provide utilities for NHS Numbers, including validity checks, normalisation, and generation.
https://nhs-number.uk-fci.tech/
MIT License
6 stars 6 forks source link

Republic of Ireland / Eire / Individual Health Identifier (IHI) Numbers and relevance to NHS Numbers #9

Closed pacharanero closed 1 year ago

pacharanero commented 1 year ago

I reached out to the HSE in Ireland via a contact and received this response:

Marcus you are correct that a subset of NHS Numbers were reserved for the Republic of Ireland. Our core IHI numbers align with this bank of numbers and are currently drawn from a range of 812000000 to 859999999.

Our full IHI number is 18 digits long and the core number can be derived from this – its 10 digits long and resides in positions 8 to 17 of the full 18 digit number. We have 2 check digits in place – one at the end of the core 10 digit number (Modulus 11 check) and one at the end of the full 18 digit number (GS1 check digit). I have enclosed a document above which gives details of format of the IHI and information on how the check digits are derived.

Hopefully this gives you what you need however if you have any further questions just shout. Best, Steve Jones IHI Consumer System Technical Lead

andylaw commented 1 year ago
  1. What are the leading 7 digits of the IHI number?
  2. Are IHI numbers in scope?
pacharanero commented 1 year ago
  1. What are the leading 7 digits of the IHI number?

I'm not sure but will find out

  1. Are IHI numbers in scope?

No, I think that looks like being a separate package entirely, and not for us to build.

pacharanero commented 1 year ago

Here is a document that describes more about the IHI IHI Format.docx It doesn't appear to clearly identify what the leading 7 digits are intended to convey.

I did read someone's MSc dissertation about proposed IHI formats which concluded that there is a slowly-forming international consensus around using a globally-unique health identifier number, so perhaps the leading digits are simply a country identifier.

There is also a very similar document which was released by HIQA and is available via the Irish Computer Society website https://www.hiqa.ie/sites/default/files/2017-02/International-Review-of-Unique-Health-Identifiers-for-Individuals.pdf

Further information https://www.ics.ie/news/view/1150

pacharanero commented 1 year ago

It doesn't appear to clearly identify what the leading 7 digits are intended to convey.

Further information from Steve Jones at HSE:

Yes, the first seven digit GS1 code is intended to ensure that the IHI number is globally unique as the GS1 code is unique to Ireland. We have 2 sets of numbers:

Production – IHI numbers starting with GS1 value ‘5393014’ Test – IHI numbers starting with GS1 value ‘5393054’

andylaw commented 1 year ago

The IHI description document tells us that the whole number is a Global Service Relation Number (see https://www.gs1.org/standards/id-keys/gsrn). This requires mental acrobatics to work out who is providing what service to whom, but basically this is the Irish Health Service declaring that they have a service relationship with the individual identified by the core 10 digit 'NHS number'. The GS1 code prefix translates as '539' == Ireland (https://www.gs1.org/standards/id-keys/company-prefix) followed by a unique code which defines the Irish Health Service as a 'company'. Presumably they have defined two companies, one for real work and one for testing.

The GS1 organisation allows 18 digits for a relationship number. One of those digits is a checksum digit (the last one). The Irish have been luck in this regard that (a) they only define one relationship so there is no need to use up digits to define what the relationship actually is and (b) that their company prefix codes are 7 digits long which just gives them room to squeeze in a 10-digit ID number.

Personally, I think this is an example of someone trying to re-use a standard and ending up being too clever for their own good

pacharanero commented 1 year ago

Personally, I think this is an example of someone trying to re-use a standard and ending up being too clever for their own good

I would tend to agree, this seems to be a slightly overcomplicated mashup of NHS number and GSRN/GS1. But hey, this is what they have gone for, we don't need to actually worry about it, I just wanted to know how/if it fitted in with NHS numbers and now we know.

pacharanero commented 1 year ago

Closing this as not currently relevant, although is potentially of interest for the future.