[Exim] Using both fields of a multi-field lookup

Páxina inicial
Borrar esta mensaxe
Responder a esta mensaxe
Autor: Ed Symanzik
Data:  
Para: exim-users
Asunto: [Exim] Using both fields of a multi-field lookup
I want to use a single database lookup to retrieve both the
uid and home directory.

I can do this with:

  ${lookup mysql {SELECT DISTINCT uid,homedir FROM account 
    WHERE username = '${quote_mysql:$local_part}'} {$value} fail}


I can get the directory with extract like so:

directory = ${extract{homedir}{lookup thing} fail}

But, how do I get the uid without having to do another lookup?

This:

foo = ${lookup...
directory = ${extract{homedir}{$foo} fail}
user = ${extract{uid}{$foo} fail}

doesn't work.