Re: [exim] 2 MySQL Lookups in 1 condition

Top Page
Delete this message
Reply to this message
Author: Tony Finch
Date:  
To: Christian Hertel
CC: exim-users
Subject: Re: [exim] 2 MySQL Lookups in 1 condition
On Thu, 17 Feb 2005, Christian Hertel wrote:
>
> But it does not work, exim always says "condition name expected, but
> found ${lookup mysql{S". What is wrong with this line condition?
> {$lookup mysql{... works well if it stands alone, so why does it not
> work as subcondition?


${lookup is not an expansion condition, so it cannot be used by itself
as the condition part of an ${if, and{}, or or{}.

Remember that ${lookup has then/else behaviour, so it can be used to
construct and and or logic by itself.

  condition = ${lookup mysql{MYSQL_Q_VALIDLOCALEMAILADDR} \
                       {yes} {${lookup mysql{MYSQL_Q_VALIDLOCALMAILBOX} \
                                       {yes} {no} }} }


Tony.
--
<fanf@???> <dot@???> http://dotat.at/ ${sg{\N${sg{\
N\}{([^N]*)(.)(.)(.*)}{\$1\$3\$2\$1\$3\n\$2\$3\$4\$3\n\$3\$2\$4}}\
\N}{([^N]*)(.)(.)(.*)}{\$1\$3\$2\$1\$3\n\$2\$3\$4\$3\n\$3\$2\$4}}