on ‎2016 Jul 11 11:04 PM
Hi All,
I tried to write a a rule for UK postcode validation by using Match Pattern .when I test it giving right answers.
but this match pattern passing just first half postcode (AA9) also pass.
when I bind it to the postcode column it passing all the patterns except Just Numbers(12345,123456,7896-----fail) in that field.
it gives score 9.99.
Did anyone came across this problem,
please help me out or please can anyone share if they wrote the rule for this already.
Regards
Kumarr
Request clarification before answering.
Hi Adrian Thanks for the good suggestion with example.I tried the same with regular expression.
showing sample
(match_regex($POSTCODE, '[A-Z][0-9]{2} [0-9]{1}[A-Z]{2}', NULL)
match_regex($POSTCODE, '[A-Z]{2}[0-9] [0-9]{1}[A-Z]{2}', NULL)
match_regex($POSTCODE, '[A-Z][0-9][A-Z] [0-9]{1}[A-Z]{2}', NULL))
And Thanks for the link also.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
| User | Count |
|---|---|
| 15 | |
| 9 | |
| 6 | |
| 4 | |
| 4 | |
| 4 | |
| 3 | |
| 2 | |
| 2 | |
| 2 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.