If I do a search from ymail.messages for just the items in the sent folder, I get back a list of messages, one of them is as follows.
{
"mid": "2_0_0_2_4471_ALjSi2IAAQ2DUOWwXg4yHwvXzdM",
"flags": {
"isReplied": "0",
"isFlagged": "0",
"isRead": "1",
"isDraft": "0",
"isForwarded": "0",
"isHam": "0",
"isSpam": "0",
"inAddressBook": "0",
"hasAttachment": "1",
"isRecent": "1"
},
"from": {
"name": "--",
"email": "--"
},
"toEmail": "--",
"subject": "BBB",
"mimeType": "multipart/mixed",
"mimeMsgId": "<nX pHgMnFnZA>",
"receivedDate": "1357230174",
"size": "955844"
}
Yet if I do a select using a query in which this message matches, like below:
select messageInfo from ymail.messages where query = "BBB"
I get back a message with a different mid. Below you can see the result of that query is the same message, but with a slightly different mid. Here is the same message that resulted from the query.
{
"mid": "2_5_22_2_4471_ALjSi2IAAQ2DUOWwXg4yHwvXzdM",
"flags": {
"isReplied": "0",
"isFlagged": "0",
"isRead": "1",
"isDraft": "0",
"isForwarded": "0",
"isHam": "0",
"isSpam": "0",
"inAddressBook": "0",
"hasAttachment": "1",
"isRecent": "1"
},
"from": {
"name": "--",
"email": "--"
},
"toEmail": "--",
"subject": "BBB",
"mimeType": "multipart/mixed",
"receivedDate": "1357230174",
"size": "955844",
"folderInfo": {
"fid": "%40S%40Search",
"name": "@S@Search"
},
"sourceFolderInfo": {
"fid": "Sent",
"name": "Sent"
},
"searchinfo": {
"snippets": "^_BBB^_",
"matchedFields": [
"body",
"subject"
]
}
}
It looks like the first segment of the mid is being generated according to some logic which causes it to vary depending upon the select. Pretty obviously, this is screwed and hoses up the ability to rely on the mid when using a query. Any help would be greatly appreciated as this sure seems to be a material bug in YQL and mail usage.