1 Jun 2004 12:40
Re: Missing postgres index
Aaron Stone wrote: > Ilja Booij <ilja@...> said: > > [snip] > >>change the query for the special case of 'INBOX' to: >> >>SELECT mailbox_idnr FROM mailboxes WHERE name = 'INBOX' and owner_idnr = >>'%llu'; >> >>We always store 'INBOX' as 'INBOX' (all caps), so, this will always >>work. And we have no problem with indexes this way. >> >>It just too simple probably.. Perhaps I'm overlooking something? >> >>Ilja >> > I'm worried about situations where the mailbox may have been created > incorrectly or somehow changed. On the other hand, because we're always > calling (or *should* always be calling) through db_find_create_mailbox, if > INBOX is for some reason Inbox, then a new INBOX will be created. I'm not sure > if the old Inbox would still be accessible, though, because of the special case... That's a valid concern, yes. However, I thing we should make sure that INBOX is always uppercase. If we do that, we're sure that the query always works. Ilja
RSS Feed