let me point you to a posting in Sourceforge forum of MXQuery:
http://sourceforge.net/forum/forum.php?thread_id=3284895&forum_id=633154
You can use the doc() function in a loop, and all files touched by the query will be updated
Regards,
Peter
Thanks
Vikram