Re: [Exim] SQL lookup fallthrough

Top Page
Delete this message
Reply to this message
Author: Bo Mellberg
Date:  
To: exim-users
Subject: Re: [Exim] SQL lookup fallthrough
> On Mon, 22 Apr 2002, Bo Mellberg wrote:
>
> > system_aliases:
> > driver = redirect
> > allow_fail
> > allow_defer
> > data = ${lookup{$local_part}lsearch{/etc/aliases}}
> > # user = exim
> > file_transport = address_file
> > pipe_transport = address_pipe
> >
> > mysql_system_aliases:
> > driver = redirect
> > allow_fail
> > file_transport = address_file
> > pipe_transport = address_pipe
> > data = ${lookup mysql{select members.emailaddress from members,
> > $local_part where members.sheetnumber =
> > $local_part.sheetnumber}{$value}fail}
> >
> >
> > after this comes the standard userforward etc.
> >
> > The lookup works fine, but if it fails, the script doesn't continue to

the
> > next router.
> > What am I doing wrong?
>
> What error message do you get?
>
> Try running with -d to see what debugging information you get.
>


When I do a "exim -bt root" it answers this:

failed to expand "${lookup mysql{select members.emailaddress from members,
$local_part where members.sheetnumber = $local_part.sheetnumber}}": lookup
of "select members.emailaddress from members, root where members.sheetnumber
= root.sheetnumber" gave DEFER: MYSQL: query failed: Table 'lve.root doesn't
exist

I have to be able to check if the table exists before I do the query. Is
that possible?

/Bo Mellberg