Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

Pixelmage

macrumors member
Original poster
Aug 22, 2008
46
0
I can't seem to get the search function in the Apple Mail to work properly. When I search any mailbox using the search field in the upper right corner of the window, there are no results. I used all kinds of search terms and selecting the "From, To, Subject, Mailbox, Attachment, and Entire Message" options and nothing appears. I can't identify the setting to correct this.
 

Patrickprett

macrumors newbie
Mar 20, 2014
5
0
Please delete your Envelope Indexes. For this, first you need to quit Mail, then delete any Envelope Indexes in your user Library/Mail/V2/MailData. Deleting the Envelope Indexes will force Mail to rebuild its database, and then hopefully it will search properly again. (Mail will ask you to "import" your messages," but it's just rebuilding its database.)
 

Weaselboy

Moderator
Staff member
Jan 23, 2005
34,171
15,691
California
Anyone try this? Does it work Ok with x10.9 - and does it generate any other problems? Thanks.

I can't guarantee this will fix the OP's problem, but deleting those envelope files will reindex Mail and won't hurt anything else. You can read about it here.

I have done it in Mavs.
 

lrall

macrumors newbie
Nov 5, 2014
1
0
For what it's worth, I was experiencing this same issue, and rebuilding the mail database or deleting envelopes did not help-- but I did find a solution. (Using Yosemite 10.10)

I went to System Preferences > Spotlight | Search Results and made sure # 12, "Mail and messages" was clicked, and then went to the "Privacy" tab and made sure that Spotlight was able to search my mail folders. I had a broad sweeping rule in there that disallowed it from indexing pretty much everything.

FYI
 

NobbyNoMates

macrumors newbie
Nov 28, 2014
1
0
Same here: I had no search results (within Mac Mail rather than Spotlight) at all.

Checked my Spotlight / privacy settings and realised that ~Library was excluded (it must have been me that did it!). I unchecked it and ta-da! results reappearing in Mac Mail ... so if you have been as dim as I then this is a quicker solution rather than rebuilding the indexes mentioned above.

(makes sense since I imagine the indexes are sitting within the ~Library folder hierarchy)
 

markusmake

macrumors newbie
May 7, 2015
1
0
Worked.

The deleting of envelopes was easy and worked perfectly for me. Did copy the envelopes just in case.

There was over 25000 mail that were indexed according to the relaunch and it took maybe one hour to finish both the indexing and importing of the mail folders and accounts.

Thank you guys!
 

Chris MacPhail

macrumors newbie
Dec 11, 2016
1
0
Worked.

The deleting of envelopes was easy and worked perfectly for me. Did copy the envelopes just in case.

There was over 25000 mail that were indexed according to the relaunch and it took maybe one hour to finish both the indexing and importing of the mail folders and accounts.

Thank you guys!

Deleting the 3 envelope files worked for me also. In my case, Spotlight Search worked fine, but searching within Apple Mail retrieved only 10% of the correct messages (excluded messages appx 1-18 months old). Browsing in Finder, I was not able to find the ~/Library/Mail/V4/MailData folder where the 3 envelope files reside. But typing that path into Finder....Go...Go to Folder brought me right there.

I am running MacOS Sierra 10.12.1. Judging from the date range of the unsearchable messages, I wonder if possibly the problem arose because I had upgraded from 10.8 to 10.11 skipping the intermediate OS X versions.
 

boppin

macrumors regular
Jun 14, 2008
173
17
Germany
Or you could also delete the mbox files.

Or better:
Copy them to desktop and remove them from the V3 folder.
 

hansuit

macrumors newbie
Dec 30, 2016
2
0
at my side deleting the 3 envelope files is not working. i'm using sierra 10.12.2
also searching in spotlight gives no result
Any other solution?
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.