Re: [Exim] filter mysql

Top Page
Delete this message
Reply to this message
Author: Peter Bowyer
Date:  
To: exim-users
Subject: Re: [Exim] filter mysql
Olivier AUDRY said:
> hi
>
> someone know how i can't store filter in a mysql base ?


A redirect router with a data = option which specifies a mysql query
should do it.. maybe

mysql_filter:
driver = redirect
allow_filter
domains = +local_domains
data = ${lookup mysql \
{select filterdata from mailtable where id='$localpart@$domain'} \
{$value}fail}

Entirely untested and will certainly need adjusting to suit your database.
Make sure the 'filterdata' starts with #Exim filter or #Sieve filter as
appropriate.

Peter