I have a requirement to match telephone numbers to a prefix within a table of prefixes. In the instance where there are multiple matches the longest number match should be selected.
0845685746 should match 08456
0845456875 should match 0845
My question is should I perform this task in a VB.net script in the SSIS package which imports the list of calls or should I stage the calls and then run a SQL script to do the matching?
Any help with the script would also be much appreciated. I am looking for the best performance solution as this may need to deal with millions of calls per import.
Thanks in advance for any help.