RegExLib.com - The first Regular Expression Library on the Web!

Please support RegExLib Sponsors

Sponsors

Advanced Search

Keywords

Category

Minimum Rating

Results per Page

Search Results: 55 regular expressions found.

Change page:   |    Displaying page 2 of 3 pages; Items 21 to 40
Title Test Details Pattern Title
Expression
^(([0-9]{5})*-([0-9]{4}))|([0-9]{5})$
Description
Accepts valid US Postal Code - either 5 digit, or extended
Matches
99999 | 99999-2222 | 999992222
Non-Matches
99999- | 99999-222
Author Rating: The rating for this expression. Clark Hay
Title Test Details Pattern Title
Expression
^[1-9]{3}\s{0,1}[0-9]{3}$
Description
Pattern for Indian Postal Code.
Matches
234 234 | 234675
Non-Matches
asd343 | 4567889 | 3454 23
Author Rating: The rating for this expression. amarkant rai
Title Test Details Pattern Title
Expression
^[1-9]{1}[0-9]{3}$
Description
This expression matches most swiss postal codes
Matches
1234 | 9876
Non-Matches
0123 | 012 | 12345
Author Rating: Not yet rated. Matt Brooke
Title Test Details Australian postal code verification
Expression
(0[289][0-9]{2})|([1345689][0-9]{3})|(2[0-8][0-9]{2})|(290[0-9])|(291[0-4])|(7[0-4][0-9]{2})|(7[8-9][0-9]{2})
Description
Accurate Australian postal code verification. Australia has 4-digit numeric postal codes with the following state based specific ranges. ACT: 0200-0299 and 2600-2639. NSW: 1000-1999, 2000-2599 and 2640-2914. NT: 0900-0999 and 0800-0899. QLD: 9000-9999 and 4000-4999. SA: 5000-5999. TAS: 7800-7999 and 7000-7499. VIC: 8000-8999 and 3000-3999. WA: 6800-6999 and 6000-6799.
Matches
0200 | 7312 | 2415
Non-Matches
0300 | 7612 | 2915
Author Rating: The rating for this expression. Vassilis Petroulias
Title Test Details Canadian postal code format verification
Expression
([ABCEGHJKLMNPRSTVXY][0-9][ABCEGHJKLMNPRSTVWXYZ])\ ?([0-9][ABCEGHJKLMNPRSTVWXYZ][0-9])
Description
Accurate Canadian postal code format verification. The format of a Canadian postal code is LDL DLD where L are alpha characters and D are numeric digits. But there are some exceptions. The letters D, F, I, O, Q and U never appear in a postal code because of their visual similarity to 0, E, 1, 0, 0, and V respectively. In addition to avoiding the six "forbidden" letters W and Z also do not appear as the first letter of a postal code (at least not at present).
Matches
M1R 4B0 | L0R 1B1 | L0R1B9
Non-Matches
W1R 4B0 | L0R 1D1 | LOR1B9
Author Rating: The rating for this expression. Vassilis Petroulias
Title Test Details German postal code verification (UPDATED)
Expression
((0[13-7]|1[1235789]|[257][0-9]|3[0-35-9]|4[0124-9]|6[013-79]|8[0124-9]|9[0-5789])[0-9]{3}|10([2-9][0-9]{2}|1([2-9][0-9]|11[5-9]))|14([01][0-9]{2}|715))
Description
Accurate German postal code verification. Germany has 5-digit numeric postal codes. The expression evaluates a postal code within state based specific ranges.
Matches
01125
Non-Matches
34125
Author Rating: The rating for this expression. Vassilis Petroulias
Title Test Details UK postal code format verification
Expression
(([A-Z]{1,2}[0-9][0-9A-Z]?)\ ([0-9][A-Z]{2}))|(GIR\ 0AA)
Description
Accurate UK postal code format verification. UK postal codes have two parts. The right part is formatted as DLL (L:letter D:digit) and the left part has six alternative formats: LD, LDL, LDD, LLD, LLDL and LLDD. There is only one exception to these formats: GIR 0AA.
Matches
M2 5BQ | EC1A 1HQ | GIR 0AA
Non-Matches
M2 BQ5 | E31A 1HQ | GIR0AA
Author Rating: The rating for this expression. Vassilis Petroulias
Title Test Details US/Canadian Addresses
Expression
^\s*((?:(?:\d+(?:\x20+\w+\.?)+(?:(?:\x20+STREET|ST|DRIVE|DR|AVENUE|AVE|ROAD|RD|LOOP|COURT|CT|CIRCLE|LANE|LN|BOULEVARD|BLVD)\.?)?)|(?:(?:P\.\x20?O\.|P\x20?O)\x20*Box\x20+\d+)|(?:General\x20+Delivery)|(?:C[\\\/]O\x20+(?:\w+\x20*)+))\,?\x20*(?:(?:(?:APT|BLDG|DEPT|FL|HNGR|LOT|PIER|RM|S(?:LIP|PC|T(?:E|OP))|TRLR|UNIT|\x23)\.?\x20*(?:[a-zA-Z0-9\-]+))|(?:BSMT|FRNT|LBBY|LOWR|OFC|PH|REAR|SIDE|UPPR))?)\,?\s+((?:(?:\d+(?:\x20+\w+\.?)+(?:(?:\x20+STREET|ST|DRIVE|DR|AVENUE|AVE|ROAD|RD|LOOP|COURT|CT|CIRCLE|LANE|LN|BOULEVARD|BLVD)\.?)?)|(?:(?:P\.\x20?O\.|P\x20?O)\x20*Box\x20+\d+)|(?:General\x20+Delivery)|(?:C[\\\/]O\x20+(?:\w+\x20*)+))\,?\x20*(?:(?:(?:APT|BLDG|DEPT|FL|HNGR|LOT|PIER|RM|S(?:LIP|PC|T(?:E|OP))|TRLR|UNIT|\x23)\.?\x20*(?:[a-zA-Z0-9\-]+))|(?:BSMT|FRNT|LBBY|LOWR|OFC|PH|REAR|SIDE|UPPR))?)?\,?\s+((?:[A-Za-z]+\x20*)+)\,\s+(A[BLKSZRAP]|BC|C[AOT]|D[EC]|F[LM]|G[AU]|HI|I[ADLN]|K[SY]|LA|M[ABDEHINOPST]|N[BCDEHJLMSTUVY]|O[HKRN]|P[AERW]|QC|RI|S[CDK]|T[NX]|UT|V[AIT]|W[AIVY]|YT)\s+((\d{5}-\d{4})|(\d{5})|([AaBbCcEeGgHhJjKkLlMmNnPpRrSsTtVvXxYy]\d[A-Za-z]\s?\d[A-Za-z]\d))\s*$
Description
This is built on an Address expression by Ross Hammer (who in turn built on an expression from Michael Ash)... and the zipcode expression from Matthew Aznoe. This one adds validation for Canadian provinces and postal codes (so it does both US and Canada)
Matches
any us/canadian address
Non-Matches
non us/candian address
Author Rating: The rating for this expression. Nick Franceschina
Title Test Details Canadian Postal Code
Expression
\b[A-Z-[DFIOQUWZ]]\d[A-Z-[DFIOQU]]\ +\d[A-Z-[DFIOQU]]\d\b
Description
Find out Canadian Postal Code in the text or html file or xml file
Matches
L4X 1S9
Non-Matches
12345
Author Rating: Not yet rated. Balram Watwani
Title Test Details Canadian postal code
Expression
\b(?([A-Z])[^DFIOQUWZ])\d(?([A-Z])[^DFIOQU])\d(?([A-Z])[^DFIOQUWZ])\d\b
Description
Matches Canadian postal codes from http://en.wikipedia.org/wiki/Canadian_postal_code. Originally I was going to use http://regexlib.com/REDetails.aspx?regexp_id=1676 but C# did not like it. I rewrote it to this version which works correctly.
Matches
K7P3K6
Non-Matches
W7P3K6
Author Rating: Not yet rated. Matthew Hartman
Title Test Details Postal code - Latvia
Expression
^(LV-)[0-9]{4}$
Description
Latvia's post code
Matches
lv-1010 LV-1013
Non-Matches
LV1010 LV 1010 lv819
Author Rating: Not yet rated. Artis
Title Test Details French postal address
Expression
((^[0-9]*).?((BIS)|(TER)|(QUATER))?)?((\W+)|(^))(([a-z]+.)*)([0-9]{5})?.(([a-z\'']+.)*)$
Description
Find differents parts of a french mail's address. 0 : Complete address 1 : Number + BIS, TER or QUATER 2 : Number 3 et 4 : BIS, TER or QUATER 5 à 9 : Nothing 10 : Street 11 : Nothing 12 : Postal code 13 : City
Matches
48 bis Avenue Des Champs Élysée 75001 Paris
Non-Matches
Rue De La Liberté 10 1000 Bruxelle
Author Rating: Not yet rated. PLAIS Lionel
Title Test Details Dutch postal codes
Expression
\b[1-9]\d{3}\ +[A-Z]{2}\b
Description
Dutch postal codes are ranged from "1000 AA" to "9999 ZZ".
Matches
"1484 EE"
Non-Matches
"1484EE", "0111 AB", "1484 ee", "1234 ABC"
Author Rating: Not yet rated. René de Leeuw
Title Test Details US zip & Canadian postal codes
Expression
^ *([AaBbCcEeGgHhJjKkLlMmNnPpRrSsTtVvXxYy]\d[a-zA-Z]) *-* *(\d[a-zA-Z]\d) *$|^ *(\d{5}) *$|^ *(\d{5}) *-* *(\d{4}) *$
Description
Matches all valid US standard, US +4, and Canadian postal codes. Returns results for only either one of them, in groups, regardless of case or whitespace (even dashes).
Matches
"H4H 3p4" "90210" "10110-4422" "v4p-5J3"
Non-Matches
"D2T1R3" "92221-133" "xv3r p1T"
Author Rating: Not yet rated. paul
Title Test Details Postal code or Pin code of India
Expression
([0-9]{6}|[0-9]{3}\s[0-9]{3})
Description
This expression will be useful to check postal code or pin code of India. This expression will check postal code or pin code in two format. One is code is separated by space after 3 digit and another is code is written in 6 digit.
Matches
360311 | 360 311 | 360 001
Non-Matches
36 0311 | 3603111 | 360 31 | 36031
Author Rating: Not yet rated. Nandip Makwana
Title Test Details Canada postal code
Expression
^[ABCEGHJKLMNPRSTVXYabceghjklmnprstvxy]{1}\d{1}[A-Za-z]{1}\d{1}[A-Za-z]{1}\d{1}$
Description
Matches the Canadian postal code with no space between.
Matches
M4S1G9 | m6p1l1 | m4s1G9
Non-Matches
M4S 1G9 | m6p 1l1 | m4s 1G9
Author Rating: Not yet rated. Nassim Ghods
Title Test Details Postal Code (Slovak Republic)
Expression
^(([0-9]{5})|([0-9]{3}[ ]{0,1}[0-9]{2}))$
Description
[en] Postal Code in Slovak Republic contains five numbers. Between 3rd and 4th number can be space. [sk] Poštové smerové císlo v Slovenskej Republike má pät císel. Medzi 3. a 4. císlicou môže byt medzera.
Matches
960 07 | 84204
Non-Matches
96 010 | 9604 | 689012
Author Rating: Not yet rated. Juraj Hajdúch (SK)
Title Test Details Canadian Postal Code
Expression
^[ABCEGHJKLMNPRSTVXYabceghjklmnprstvxy]{1}\d{1}[A-Za-z]{1}[ ]{0,1}\d{1}[A-Za-z]{1}\d{1}$
Description
Matches the Canadian postal code with or without space between. Also matches uppercase and lower case letters.
Matches
K4A3Z5 | K4A 3Z5 | k4a3z5 | k4a 3z5
Non-Matches
D1G 1T9 | abc def | 123 456 | f1g4t0
Author Rating: Not yet rated. Sheir Ali
Title Test Details Canadian Postal Code
Expression
^([a-z-[dfioquwz]]|[A-Z-[DFIOQUWZ]])\d([a-z-[dfioqu]]|[A-Z-[DFIOQU]])(\s)?\d([a-z-[dfioqu]]|[A-Z-[DFIOQU]])\d$
Description
Take in account the fact that the first letter cannot be a w or a z moreover the fact that letters cannot be any of DFIOQU
Matches
J0H 1A0
Non-Matches
W4C 8S9
Author Rating: Not yet rated. Michel Verrier
Title Test Details (Java only) Postal code check for the Netherlands
Expression
^[1-9]\d{3}\s?(?i)(?!(S[ADS]))([A-Z&&[^FIOQUY]]{2})$
Description
Java only postcodecheck for the Netherlands, case insensitive. Characters not allowed: FIOQUY Strings not allowed: SA, SD, SS
Matches
1234 AB | 1234ab
Non-Matches
1234 SS | 1234fq
Author Rating: Not yet rated. Henk-Jan de Jong
Change page:   |    Displaying page 2 of 3 pages; Items 21 to 40

Copyright © 2001-2014, RegexAdvice.com | ASP.NET Tutorials