Francois Cattin writes:
Hello,
I tried today the imap server, and I saw that the messages couldn't be
deleted (or trashed), because there was a bad SQL command:
May 15 11:53:00 calimero dbmail/imap4d[1937]: db_query(): executing query
[SELECT SUM(messagesize) FROM messages WHERE mailbox_idnr IN (SELECT
mailbox_idnr FROM mailboxes WHERE owner_idnr = 1::bigint) AND m.status <
2]
yes, that's wrong, it's also missing in dbmail-1.1 (just checked it)
it's the db_get_quotum_used() functions, 1st sql statement.
actually the right one should be
<sql>
SELECT SUM(messagesize) FROM messages WHERE mailbox_idnr IN (SELECT
mailbox_idnr FROM mailboxes WHERE owner_idnr = 1::bigint) AND status <
2]
</sql>
since status is part ot messages{} table or 'SELECT SUM(messagesize),
m.status"...." m.status < 2"
havent checked for more.
HTH
cheers,