At 11:04 PM 2/10/2009, post...@corwyn.net wrote:
At 05:24 PM 2/10/2009, mouss wrote:
While I can readily create a user b...@example.com, who has a default maildir location for that sql of 'example.com/bob/' I can't quite figure out how to change the SQL to get the folder for bob+t...@example.com to return:

'example.com/bob/Maildir/.test' without breaking everything else?

To answer my own question (more correctly)
SELECT CONCAT(maildir,'Maildir/',if(INSTR(username,'+'),'.',''),if(INSTR(username,'+'),MID(username,INSTR(username,'+')+1,INSTR(username,'@')-INSTR(username,'+')-1),'')) FROM mailbox


Rick


Reply via email to