Submit Hint Search The Forums LinksStatsPollsHeadlinesRSS
14,000 hints and counting!

10.4: Another method to force iPhoto Spotlight indexing System 10.4
Tiger only hintIf you have an iPhoto library that you've upgraded to Tiger, you may have noticed that most of your iPhoto keywords and comments aren't indexed by Spotlight! It turns out that Spotlight only notices comments added by iPhoto 5.0.2 or later, which is why a search for my baby daughter's name only turned up 6 of the 550 photos I've taken of her.

Luckily, there's a simple fix to get all of your photos indexed. First, bring up the information toolbox (Command-I), and select the Keywords pane. Next select your entire iPhoto library (Command-A). Now check *any* keyword that has an empty checkbox next to it (make a new one in the preferences if necessary), wait a second or two for the change to take effect, and uncheck it. Voila! All of your keywords and comments are now indexed.

[robg adds: 550 photos? I'm guessing the baby isn't much older than a month, judging by my own history :)! There's another hint here on indexing iPhoto stuff; there's some evidence that the first method didn't work for some people, so I'm running this one as an alternative solution.]
    •    
  • Currently 3.25 / 5
  You rated: 4 / 5 (4 votes cast)
 
[15,427 views]  

10.4: Another method to force iPhoto Spotlight indexing | 8 comments | Create New Account
Click here to return to the '10.4: Another method to force iPhoto Spotlight indexing' hint
The following comments are owned by whoever posted them. This site is not responsible for what they say.
10.4: Another method to force iPhoto Spotlight indexing
Authored by: MacDork on May 26, '05 01:26:20PM

<blockquote>First, bring up the information toolbox (Command-I)</blockquote>

In what application??



[ Reply to This | # ]
10.4: Another method to force iPhoto Spotlight indexing
Authored by: n8gray on May 26, '05 07:43:27PM

iPhoto. Sorry, I thought that was obvious.



[ Reply to This | # ]
10.4: Another method to force iPhoto Spotlight indexing
Authored by: fortepianissimo on May 26, '05 03:19:56PM

I tried this, by checking and unchecking different keywords - but didn't work for me. I still couldn't find even a single picture in iPhoto!

I also tried

mdimport -r /System/Library/Spotlight/iPhoto.mdimporter

and it didn't work either.



[ Reply to This | # ]
10.4: Another method to force iPhoto Spotlight indexing
Authored by: barrysharp on May 26, '05 05:04:17PM

I used this technique a week ago and this is what I did.

1. Launch iPhoto
2. Select Toolbar's iPhoto->Preferences
3. Select "Keywords"
4. Click "Add" button and enter a new key, say "Temp"
5. Click the Preferences red button to clear the Preference window
6. Select "Library" in the iPhoto Source List (ie the top one)
7. Press Command+A (to select all photos in the Libary
8. Click the 'key' icon button at opposite end to where you see the "+" button in bottom left hand corner of the iPhoto window
9. Select Toolbar's Photos->Get Info and then select Keywords tab
10. Select the keyword "Temp" checkbox
11. Shortly you will see "Temp" under every photo (make sure you have Toolbar's View->Keywords checked otherwise you will not see this "Temp" keyword under your photos)
12. This keyword assigned to ALL your photos will cause Spotlight to index ALL your iPhoto Library.
13. Remove the keyword "Temp" from all your photos by unselecting the check box you selected in step 10.
14. ALL DONE.

Hope that helps.


---
Regards... Barry Sharp



[ Reply to This | # ]
10.4: Another method to force iPhoto Spotlight indexing
Authored by: n8gray on May 26, '05 07:35:42PM
550 photos? I'm guessing the baby isn't much older than a month, judging by my own history :)!

Actually about 4 months. I consciously scaled back my picture taking after the first month so that she wouldn't go blind from flashbulbs popping in her face every 10 minutes. :-)

[ Reply to This | # ]

10.4: Another method to force iPhoto Spotlight indexing
Authored by: Mucho Grande on May 27, '05 02:48:39AM
This seemed to work for me, and I posted it on the other thread. From what I have seen, Spotlight only includes the comments from an iPhoto picture if they have been made after the installation of Spotlight. This script will copy the photo's comment, remove it, then put it back.


-- A quick script to make your iPhoto comments searchable
-- in Spotlight.
--
-- All it does, is remove the comments of a photo, and then
-- puts it back.
--
--
tell application "iPhoto"
	activate
	-- First get all the photos in the library.
	set edit_photos to (every photo of photo library album)
	-- Go through each individual photo
	repeat with edit_photo in edit_photos
		-- Store the comment of the photo, remove it, and then
		-- put it back.
		set photo_comment to comment of edit_photo
		set comment of edit_photo to ""
		set comment of edit_photo to photo_comment
	end repeat
end tell


[ Reply to This | # ]
10.4: Another method to force iPhoto Spotlight indexing
Authored by: n8gray on May 27, '05 05:31:55PM

FWIW, adding/removing a keyword also got all of the comments idexed for me as well.



[ Reply to This | # ]
10.4: Another method to force iPhoto Spotlight indexing
Authored by: jaysoffian on Mar 03, '06 05:26:19PM
I just filed this bug with Apple after finally figuring out why my photos weren't getting picked up by spotlight:

iPhoto allows you to place comments on Folders, Albums, and Smart Albums.
However, if the comment is multiline the newline causes mdimport to choke on
AlbumData.xml

To reproduce:

- In iPhoto, File -> New Folder
- Select the new folder in the iPhoto Source pane.
- In the iPhoto Information pane (click (i) if needed to expose it), click in
  the comments box and then type any multiline comment. e.g.
  "hello<return>world"
- Quit iPhoto
- In the Terminal, run mdimport on the library:

callisto:~/Pictures/iPhoto Libraries% mdimport Test
*** Parsing file: '/Users/jay/Pictures/iPhoto Libraries/Test/AlbumData.xml'
ERROR: syntax error (<key>PhotoCount</key>)

Single line comments work fine. I believe the problem is that iPhoto places
the newline literally in the XML file instead of escaping it:

            <key>Comments</key>
            <string>hello
world</string>

The same problem occurs when placing multiline comments on Albums and Smart
Albums (I didn't test other sources such as Slideshows or Books).

Multiline comments on images appear to work fine, though I note the newline is
not escaped in the XML file on them either.
This is with iPhoto 6.0.2 and 10.4.5.

[ Reply to This | # ]