Loading ...
Sorry, an error occurred while loading the content.

Re: Postfix frontend on existing MySQL DB (routing problems)

Expand Messages
  • Simone Felici
    ... Good morning mouss! This is really a good morning for me, because, this solution WORKS!!!! Thank s a loooot!!!! Have a nice day! Simon -- Simone Felici
    Message 1 of 16 , Jul 2, 2007
    • 0 Attachment
      mouss ha scritto:
      > mouss wrote:
      >>
      >> Before you get mad, here is how a way to solev your problem:
      >>
      >> query = SELECT CONCAT('smtp:', next) FROM smtproutes where
      >> domain = '%d' and %u = IF(account = '', %u, account)
      >
      > silly me, this is the same as OR. don't use it.
      >
      > use this:
      >>
      >>
      >> query = SELECT CONCAT('smtp:', next) FROM smtproutes where
      >> domain = '%d' and
      >> (acount = '%u' or account = '')
      >> order by length(account) desc limit 1
      >
      > an approach that doesn't require "advanced" sql statements is:
      >
      > transport_maps =
      > proxy:mysql:/path/to/transport_users.cf
      > proxy:mysql:/path/to/transport_domains.cf
      >
      > in transport_users, use the query with '%u' = account
      > in transport_domains, use the same query but with '%u' = ''
      >
      >
      >



      Good morning mouss!

      This is really a good morning for me, because, this solution WORKS!!!!


      Thank's a loooot!!!!

      Have a nice day!

      Simon

      --
      Simone Felici E-Mail: s.felici@...
      Divisione Tecnica Tel: 0461 030 111
      Alpikom S.p.A. Fax: 0461 030 112
      v.Fersina, 23 - 38100 Trento URL: http://www.alpikom.it
    Your message has been successfully submitted and would be delivered to recipients shortly.