Re: Email Verfication Regular Expression

From: Steve Atkins <steve(at)blighty(dot)com>
To: pgsql-general(at)postgresql(dot)org
Subject: Re: Email Verfication Regular Expression
Date: 2005-09-13 19:06:36
Message-ID: 20050913190636.GB24285@gp.word-to-the-wise.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On Tue, Sep 13, 2005 at 09:02:46PM +0200, Peter Eisentraut wrote:
> Steve Atkins wrote:
> > If you want to validate email addresses you _must_ check the TLD as
> > part of the sanity checking, as many of the typos that are
> > theoretically detectable are detectable by that check.
>
> Your requirements may be different than mine, but I often make up "fake"
> TLDs for testing or even internal subnets in production systems, so
> having a system that hardcoded the list of "official" TLDs would be
> significantly less useful to me.

It depends on the needs. For a purely internal application your needs
are defined by your local setup. Those are not "internet email
addresses", though.

If you're accepting email addresses from Joe Public with the
expectation of sending email to them, then you really want to do as
much validation as you can at data capture time, or if not then at
data import time.

It's very, very hard to validate email addresses, but avoiding the
usual typos, mistakes and misunderstandings is a very good idea
and can keep your set of email addresses at least somewhat clean.

(I pity the poor folks at noemail.com and aol.co, though...)

Cheers,
Steve

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Karsten Hilbert 2005-09-13 19:07:14 GNUmed release 0.1 announcement
Previous Message Tom Lane 2005-09-13 19:02:54 Re: Speed problems