From: Bradley Giesbrecht on
Hi,


mail_version = 2.6.1

I using virtual_alias_maps with mysql for storage. Working fine.

Does anyone have a suggestion on how to update a timestamp field in
the mysql table when postfix finds a virtual_alias_maps match?

I'm looking for a way to measure alias usage and cull unused aliases.


Thank you,
Bradley Giesbrecht

From: Serge Fonville on
Hi,

> I using virtual_alias_maps with mysql for storage. Working fine.
>
> Does anyone have a suggestion on how to update a timestamp field in the
> mysql table when postfix finds a virtual_alias_maps match?
>
> I'm looking for a way to measure alias usage and cull unused aliases.
Have you considered a stored procedure?

HTH

Regards,

Serge Fonville



--
http://www.sergefonville.nl

Convince Google!!
They need to support Adsense over SSL
https://www.google.com/adsense/support/bin/answer.py?hl=en&answer=10528
http://www.google.com/support/forum/p/AdSense/thread?tid=1884bc9310d9f923&hl=en

From: Brian Evans - Postfix List on
On 1/28/2010 3:35 PM, Serge Fonville wrote:
> Hi,
>
>> I using virtual_alias_maps with mysql for storage. Working fine.
>>
>> Does anyone have a suggestion on how to update a timestamp field in the
>> mysql table when postfix finds a virtual_alias_maps match?
>>
>> I'm looking for a way to measure alias usage and cull unused aliases.
>>
> Have you considered a stored procedure?
>

Stored procedures do not work in Postfix without code changes because
the |CLIENT_MULTI_RESULTS connect flag, for MySQL API, is not turned on.
|

From: Serge Fonville on
>>> I using virtual_alias_maps with mysql for storage. Working fine.
>>>
>>> Does anyone have a suggestion on how to update a timestamp field in the
>>> mysql table when postfix finds a virtual_alias_maps match?
>>>
>>> I'm looking for a way to measure alias usage and cull unused aliases.
>>>
>> Have you considered a stored procedure?
>>
>
> Stored procedures do not work in Postfix without code changes because
> the |CLIENT_MULTI_RESULTS connect flag, for MySQL API, is not turned on.

From the manual:
http://dev.mysql.com/doc/refman/5.0/en/mysql-real-connect.html
CLIENT_MULTI_RESULTS
Tell the server that the client can handle multiple result sets from
multiple-statement executions or stored procedures. This flag is
automatically enabled if CLIENT_MULTI_STATEMENTS is enabled. See the
note following this table for more information about this flag.
If your program uses CALL statements to execute stored procedures, the
CLIENT_MULTI_RESULTS flag must be enabled.

Not sure if I understand this right then, but to me this reads that if
you use SELECT to get results from a stored procedure your fine

Correct me if I'm wrong

HTH

Regards,

Serge Fonville
--
http://www.sergefonville.nl

Convince Google!!
They need to support Adsense over SSL
https://www.google.com/adsense/support/bin/answer.py?hl=en&answer=10528
http://www.google.com/support/forum/p/AdSense/thread?tid=1884bc9310d9f923&hl=en

From: Brian Evans - Postfix List on
On 1/28/2010 4:12 PM, Serge Fonville wrote:
>>>> I using virtual_alias_maps with mysql for storage. Working fine.
>>>>
>>>> Does anyone have a suggestion on how to update a timestamp field in the
>>>> mysql table when postfix finds a virtual_alias_maps match?
>>>>
>>>> I'm looking for a way to measure alias usage and cull unused aliases.
>>>>
>>>>
>>> Have you considered a stored procedure?
>>>
>>>
>> Stored procedures do not work in Postfix without code changes because
>> the |CLIENT_MULTI_RESULTS connect flag, for MySQL API, is not turned on.
>>
> From the manual:
> http://dev.mysql.com/doc/refman/5.0/en/mysql-real-connect.html
> CLIENT_MULTI_RESULTS
>
>
[...]
> If your program uses CALL statements to execute stored procedures, the
> CLIENT_MULTI_RESULTS flag must be enabled.
>
Reread this ^^^.