are all us zip codes 5 digits?

Discussion in 'Off Topic' started by TechBoyJK, Dec 29, 2009.

  1. TechBoyJK

    TechBoyJK Lifer

    Joined:
    Oct 17, 2002
    Messages:
    16,502
    Likes Received:
    40
    Are all us zip codes 5 digits?

    aka St. Louis 63102

    I know there can be 63102-4567 but thats not what im talking about.. are there any 4 or 7 digit zips??
     
  2. nickbits

    nickbits Diamond Member

    Joined:
    Mar 10, 2008
    Messages:
    4,125
    Likes Received:
    0
    everything is 5 or 5+4
     
  3. Abel007

    Abel007 Platinum Member

    Joined:
    Jun 12, 2001
    Messages:
    2,169
    Likes Received:
    0
  4. edro

    edro Lifer

    Joined:
    Apr 5, 2002
    Messages:
    24,328
    Likes Received:
    63
    Yes, although some start with 0.
     
  5. FoBoT

    FoBoT No Lifer

    Joined:
    Apr 30, 2001
    Messages:
    63,094
    Likes Received:
    5
    they are nine digits
     
  6. olds

    olds Elite Member

    Joined:
    Mar 3, 2000
    Messages:
    48,724
    Likes Received:
    52
    Chuck Norris' zip code is 1.
     
  7. Chronoshock

    Chronoshock Diamond Member

    Joined:
    Jul 6, 2004
    Messages:
    4,861
    Likes Received:
    1
    No offense, but your address parser is probably going to be broken. Instead of trying to reinvent it, I'd suggest finding one that already exists...
     
  8. TechBoyJK

    TechBoyJK Lifer

    Joined:
    Oct 17, 2002
    Messages:
    16,502
    Likes Received:
    40
    lol.. it almost works already. And one doesn't exist in the context I need it. I found a few entries in the zip db that were like 501 but thats only because it wasn't displaying the leading 00's, which threw me off.

    It can already grab the zip out and find the city state.
     
  9. thepd7

    thepd7 Diamond Member

    Joined:
    Jan 2, 2005
    Messages:
    9,431
    Likes Received:
    0
    yes. everyone knows this.
     
  10. TechBoyJK

    TechBoyJK Lifer

    Joined:
    Oct 17, 2002
    Messages:
    16,502
    Likes Received:
    40
    thats what I thought.. then i found a 3 digit zip code in a zipcode database. I just didn't realize it wasn't showing the leading 00. It caused me a 'wtf' moment
     
  11. Train

    Train Lifer

    Joined:
    Jun 22, 2000
    Messages:
    13,652
    Likes Received:
    2
    And some start wih 00

    IIRC the first zip code is 00510. A bitch when coding because the computer always wants to chop off leading zeros. Some software is friendly enough to accept just the 510, others assume you made an error so you have to add the leading zeros.
     
  12. Evadman

    Evadman Administrator Emeritus<br>Elite Member

    Joined:
    Feb 18, 2001
    Messages:
    30,990
    Likes Received:
    3
    SET @ZipCode = right('00000'+@ZipCode,5)

    strZipCode = right("00000" & cstr(strZipCod),5)

    function IsAZip(value) {
    var re = /^\d{5}([\-]\d{4})?$/;
    return (re.test(value));
    }

    bla bla bla
     
  13. SirStev0

    SirStev0 Lifer

    Joined:
    Nov 13, 2003
    Messages:
    10,434
    Likes Received:
    1
    In Australia they are 5 but they are all backwards. I mean its on the other side of the world.