NAME
Medical::NHSNumber - Check if an NHS number is valid
VERSION
Version 0.01
SYNOPSIS
Everyone registered with the NHS in England and Wales has their own unique NHS number. The NHS number enables health care professionals in the UK to obtain, link and index electronic health records for an individual across a multiple sources of clinical information.
Given a new-style NHS number, returns true if the number is valid and false if the number appears to be invalid.
use Medical::NHSNumber;
my $nhs_no = '1234561234';
my $rv = Medical::NHSNumber::is_valid( $nhs_no );
The validation is performed using the Modulus 11 algorith. More details on the exact implementation followed can be found on the NHS Connecting for Health website at http://www.connectingforhealth.nhs.uk/industry/docs/pds/index.html?dat_nhs_no.htm
Additional information on Modulus 11 can also be found on this HP site http://docs.hp.com/en/32209-90024/apds02.html
Please note, this module will only check the validity of new style NHS numbers i.e. ten digit numbers. There are over 21 different formats for older styles of NHS numbers which currently, this module does not support. If you do happen to know the specifics for the older versions and would like to tell me, I would be more than happy to incorporate some logic for them.
FUNCTIONS
is_valid
Given a new-style NHS number, returns true if the number is valid and false if the number appears to be invalid.
my $rv = Medical::NHSNumber::is_valid( $nhs_no );
AUTHOR
Dr Spiros Denaxas, <s.denaxas at gmail.com>
BUGS
Please report any bugs or feature requests to bug-medical-nhsnumber at rt.cpan.org
, or through the web interface at http://rt.cpan.org/NoAuth/ReportBug.html?Queue=Medical-NHSNumber. I will be notified, and then you'll automatically be notified of progress on your bug as I make changes.
SUPPORT
You can find documentation for this module with the perldoc command.
perldoc Medical::NHSNumber
You can also look for information at:
RT: CPAN's request tracker
AnnoCPAN: Annotated CPAN documentation
CPAN Ratings
Search CPAN
COPYRIGHT & LICENSE
Copyright 2009 Dr Spiros Denaxas.
This program is free software; you can redistribute it and/or modify it under the terms of either: the GNU General Public License as published by the Free Software Foundation; or the Artistic License.
See http://dev.perl.org/licenses/ for more information.