>>hostlist domain_reject = ${lookup mysql {SELECT concat(domain, ' : ')
>>from domain_reject order by domain}}
>>
> By default a query-style ${lookup ...} expansion returns all matching records 
> separated by *newlines*, not the colons you need. And since you have to 
> extract all records and match against each in turn you could simply put all 
> patterns in a text file, one pattern per line, and refer to it by filename, 
> 

Hi, and thanks for the reply!

I'm a bit confused though.  It sure does put '\n' there, but this does 
not seem to affect all other sql-based lookups, such as virtual hosts, 
domains, users, host_reject_rcpt list etc.  All works fine except this 
one, and the debug output shows that the '\n' is there in every sql 
response:

10.0.0.0/8 :
172.16.0.0/12 :
192.168.0.0/16 :
...
which is the beginning of my host_reject_rcpt:

hostlist host_reject_rcpt = ${lookup mysql {SELECT concat(host, ' : ') 
from host_reject order by host}}

text file is something i'm trying to avoid, as all of the MX hosts are 
using the same sql table, therefore i don't need to distribute the same 
text file every time i make a change.

thanks
Adam

-- 
## List details at http://www.exim.org/mailman/listinfo/exim-users 
## Exim details at http://www.exim.org/
## Please use the Wiki with this list - http://www.exim.org/eximwiki/

Reply via email to