Why do you need this? If you're on 7.4 then most likely you also have the new IDoc monitor transaction WLF_IDOC that can search for the segment content. It runs quite fast in our environment and is much more convenient than the old WE09 transaction.
If you still must have a custom report then maybe it's worth checking the code in that transaction.