[ Charset ISO-8859-1 unsupported, converting... ]
> Hi,
> 
> I just want to order by a listing of email address by domain like :
> 
> [EMAIL PROTECTED]
> [EMAIL PROTECTED]
> [EMAIL PROTECTED]
> [EMAIL PROTECTED]
> [EMAIL PROTECTED]
> 
> Is it possible and how ?

Good question.  I have shell script I use to look for network duplicates
in my SPAM database so I can block even more networks.  What I do is run
the program through 'rev' (on BSD/OS, not sure about other OS's) that
reverses the characters on every line, then run it though sort, the use
'rev' again to unreverse them.  It groups duplicate hosts/networks
together, but does not order things properly:

        [EMAIL PROTECTED]
        [EMAIL PROTECTED]

ad is after ac because the sorting is done on moc.cb@x and moc.da@x, and
c is before d.

Not sure if that helps, but that I what I did.  Not sure how to do that
in the database.  Seems you will have to strip off the username@ part
and sort just the host name, then put it back.

-- 
  Bruce Momjian                        |  http://candle.pha.pa.us
  [EMAIL PROTECTED]               |  (610) 853-3000
  +  If your life is a hard drive,     |  830 Blythe Avenue
  +  Christ can be your backup.        |  Drexel Hill, Pennsylvania 19026

---------------------------(end of broadcast)---------------------------
TIP 5: Have you checked our extensive FAQ?

http://www.postgresql.org/users-lounge/docs/faq.html

Reply via email to