Solved

convert UK vehicle registration numbers into year of registration

Posted on 2011-03-03
7
433 Views
Last Modified: 2012-05-11
Hi guys,

Has anyone got any code that will determine year of registration from UK license plates?

eg...
LD10AAA = 2010
AB60AAA = 2010
LD11BBB = 2011
CD55BBB = 2005
X123ABC = 2000
X12ABC = 2000
X1ABC = 2000
M123ABC = 1996
.....


I'm aware that code won't be right in all cases and that personalised plates obfuscate year of reg.

Many thanks
Jon



0
Comment
Question by:jondanger
7 Comments
 
LVL 24

Expert Comment

by:StephenJR
ID: 35026879
You would need I think to construct a look-up table with the various codes/types of code in one column and the year in the second column. I lost track of number plates once they got rid of the letter at the end so am not currently au fait.
0
 

Author Comment

by:jondanger
ID: 35026922
lol yes fair play... i could figure it out the donkey way.

I'm hoping someone else has done this and is willing to share.
0
 
LVL 24

Expert Comment

by:StephenJR
ID: 35026945
Do you know what the rules are - from your list there doesn't appear to be much logic, but presumably there is?
0
PRTG Network Monitor: Intuitive Network Monitoring

Network Monitoring is essential to ensure that computer systems and network devices are running. Use PRTG to monitor LANs, servers, websites, applications and devices, bandwidth, virtual environments, remote systems, IoT, and many more. PRTG is easy to set up & use.

 
LVL 50

Assisted Solution

by:barry houdini
barry houdini earned 250 total points
ID: 35027011
Hello Jon,

Isn't the last one 1994?

Here's a formula approach, assuming that letter codes from 1983 to 2001 are shown in table codes

=IF(ISERR(MID(A2,2,1)+0),MOD(MID(A2,3,2),50)+2000,VLOOKUP(LEFT(A2),Codes,2,0))

or without a table you can use this longer version

=IF(ISERR(MID(A2,2,1)+0),MOD(MID(A2,3,2),50)+2000,IF(LEFT(A2)="U",17,IF(LEFT(A2)="X",18,MATCH(LEFT(A2),{"A","B","C","D","E","F","G","H","J","K","L","M","N","P","R","S","T","W","Y"},0)))+1982)

see both versions in the attached

regards, barry
26860856barry.xls
0
 
LVL 6

Accepted Solution

by:
akajohn earned 250 total points
ID: 35027208
Hi
Got a slightly different version from barry.
I used http://en.wikipedia.org/wiki/Vehicle_registration_plates_of_the_United_Kingdom
I got slightly different results and only checked for the codes up to 1983 approx.

Hope this helps.
A>
UKLicensePlateLookup.xls
0
 
LVL 45

Expert Comment

by:patrickab
ID: 35043131
Prefix letter year codes UK - see below...
Ref:

http://en.wikipedia.org/wiki/Vehicle_registration_plates_of_the_United_Kingdom#Year_identifiers
Letter 	Dates of issue
A 	1 August 1983 – 31 July 1984
B 	1 August 1984 – 31 July 1985
C 	1 August 1985 – 31 July 1986
D 	1 August 1986 – 31 July 1987
E 	1 August 1987 – 31 July 1988
F 	1 August 1988 – 31 July 1989
G 	1 August 1989 – 31 July 1990
H 	1 August 1990 – 31 July 1991
J 	1 August 1991 – 31 July 1992
K 	1 August 1992 – 31 July 1993
L 	1 August 1993 – 31 July 1994
M 	1 August 1994 – 31 July 1995
N 	1 August 1995 – 31 July 1996
P 	1 August 1996 – 31 July 1997
R 	1 August 1997 – 31 July 1998
S 	1 August 1998 – 28 February 1999
T 	1 March 1999 – 31 August 1999
V 	1 September 1999 – 29 February 2000
W 	1 March 2000 – 31 August 2000
X 	1 September 2000 – 28 February 2001
Y 	1 March 2001 – 31 August 2001

Open in new window

0
 

Author Comment

by:jondanger
ID: 35111250
thanks guys, both precise and elegant!
0

Featured Post

Master Your Team's Linux and Cloud Stack

Come see why top tech companies like Mailchimp and Media Temple use Linux Academy to build their employee training programs.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Best Excel  formula for  this scenario 2 39
Copy a range from 1..n excel sheets to one destination sheet 2 35
Msbbox Notice (4 days) 27 59
Excel Drop Down List 13 35
If you need to start windows update installation remotely or as a scheduled task you will find this very helpful.
This article descibes how to create a connection between Excel and SAP and how to move data from Excel to SAP or the other way around.
This Micro Tutorial demonstrates how to create Excel charts: column, area, line, bar, and scatter charts. Formatting tips are provided as well.
This Micro Tutorial will demonstrate on a Mac how to change the sort order for chart legend values and decrpyt the intimidating chart menu.

832 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question