Subject: MSGNO and UID

From: Raul Dias <[email-masked]>
Date: Mon, 5 Nov 2001 17:46:47 -0300

Hi,

I am thinking in a situation with the Message Number (MSGNO) of a message in a mailbox.

If the last message (lets say MSGNO = 100 an X-UID = 100)  is deleted and 
expunged from a open mailbox.
If procmail (or another MDA)  delivers a new message, will it get the old MSGNO (100) and 
UID 101?

or the MSGNO will also be 101?

Suposing that UID = 100 was the biggest uid in the mailbox before the new one arrives.

Is it dangerous to be based on MSGNO?

Can I reset the UID numbering? So that it would start from 1 in the current mailbox.

Regards,

Raul Dias

-- 
------------------------------------------------------------------
 For information about this mailing list, and its archives, see: 
 http://www.washington.edu/imap/c-client-list.html
------------------------------------------------------------------

---

From: Mark Crispin <[email-masked]>
Date: Mon, 5 Nov 2001 12:56:25 -0800 (PST)

On Mon, 5 Nov 2001 17:46:47 -0300, Raul Dias wrote:
> If procmail (or another MDA)  delivers a new message, will it get the old
> MSGNO (100) and UID 101?

Yes.  MSGNOs are always from 1 to number-of-messages.

UIDs are uniquely assigned, and are never reused.

Thus, MSGNO==UID can only happen in a mail store which assigns UIDs
consecutively from 1, in a mailbox that has never had any messages expunged.

> Can I reset the UID numbering? So that it would start from 1 in the current

You can not reset UID numbering without resetting UIDVALIDITY.  You should
avoid doing that.