If alphanumeri开发者_开发技巧c all numbers can't be 9's.
If lengh of the string 7 must be 1 alpha + 6 numeric.
UPDATED: For the first part
if alphanumeric all numbers can't be 9's
and seeing that A999999 is not possible. It should not match this
[a-zA-Z]{1,2}[^9]{6}
but it should match this.
[a-zA-Z]{1,2}[0-9]{6}
精彩评论