274 karma · joined Apr 23, 2017 (9y ago) · 100 submissions
comment 2y ago · link · parent
comment 3y ago · link · parent
comment 4y ago · link · parent
comment 4y ago · link · parent
comment 4y ago · link · parent
comment 4y ago · link · parent
comment 4y ago · link · parent
virtual_alias_maps = mysql:/etc/postfix/mysql_virtual_alias_maps.cf,
mysql:/etc/postfix/mysql_virtual_alias_maps_wildcard.cf,
hash:/etc/postfix/virtual
The first file is just regular aliases, and is basically a simpler version of the second file (no SQL selections/filters) and could also be merged into a single query with the second file: user = mail
password = <password>
hosts = 127.0.0.1
dbname = maildb_postfix
query = SELECT a1.goto FROM alias a1
LEFT JOIN alias a2 on (a2.address = '%s')
WHERE '%s' LIKE a1.address
AND a1.active = '1' AND a2.address IS NULL
This works, because the percent sign in the alias is picked up by the LIKE keyword. A setup like this allows me to configure many aliases through Postfix Admin's web admin page, including optional wildcard aliases (depending on which users wants that). It has been working very well for me over the past 15+ years. Also, I haven't looked at that SQL query since then and would likely write it in a nicer way today.Note: with the above code SQL injection could be possible through an alias name, but given that in this setup I am the only one managing the mail accounts, I was willing to take this risk. :-) Postfix Admin might do some cleaning/validation, but I haven't checked on it.
comment 4y ago · link · parent
comment 5y ago · link · parent
comment 5y ago · link · parent
comment 5y ago · link · parent
comment 5y ago · link · parent
Among other things it says the excess death in last December among members of a large health insurer (AOK) rose to 250% of the previous year in various heavy hit regions like Zwickau, Görlitz and Sächsische Schweiz ("So stieg die Übersterblichkeit im vergangenen Dezember unter den sächsischen AOK-Mitgliedern in den Landkreisen Zwickau, Görlitz und Sächsische Schweiz auf 250 Prozent des Vorjahresniveau.").
comment 5y ago · link · parent
> This latter equivalence does not hold exactly when more than two tables appear, because JOIN binds more tightly than comma. For example FROM T1 CROSS JOIN T2 INNER JOIN T3 ON condition is not the same as FROM T1, T2 INNER JOIN T3 ON condition because the condition can reference T1 in the first case but not the second.
[1] https://www.postgresql.org/docs/current/queries-table-expres...