Storing Last Login Plugin value in SQL
dovecot at ptld.com
dovecot at ptld.com
Tue Sep 14 00:44:17 EEST 2021
> Assuming you use MariaDB / MySQL, you create this trigger in the
> database.
> Assuming your int/bigint/varchar column is lastlogin and the table name
> is mailacct,
> the trigger will update the datetime `logindate` column whenever the
> table is updated,
> by whatever existing queries you have. This is your recourse when you
> can't get your
> queries to do the right thing in the first place.
Thank you for the solution of using sql triggers. I was able to get it
working that way.
I hope it doesn't add too much overhead as it feels like a band-aid and
duct-tape fix.
More information about the dovecot
mailing list