Newbie question re updates to an indexed DB

I read a question a few messages down from this one enquiring as to an
'update' feature. While I'm not requiring an update feature as such, I
was wondering what the recommended approach would be to when a DB is
indexed, and then FK relationships change in the DB i.e. what's the
most efficient way to update/reindex the index?

I previously posted a comment about my own domain model which consists
of an Account with 1 or more Profiles which in turn has 0 or more
Devices. Devices can be moved between Profiles. If I have indexed the
Device data flattening it out to include the Profile data, what's the
most efficient way to now update my index? The DB update is as simple

update device set profile_id = ? where id in (?, ?, ...?)

Obviously it won't be that simple in the Lucene index. :frowning: