You can type on the command line, WRKMSGD and hit enter and it will take you to the error messages.
Hope that helps.
There is a large amount of information that the system has related to a message — enough to really clutter up a display with information one generally isn’t interested in.
If you are receiving the message with the RCVMSG command, the Receive Program Message API QMHRCVPM, or the Receive Nonprogram Message API QMHRCVM then all three have the option to return the message file name and library. For RCVMSG these are the MSGF, MSGFLIB, and SNDMSGFLIB keywords. SNDMSGFLIB by the way indicates the library used by the sender — which in a multilingual environment might not be the same library as you are using to “see” the message.
Hope this helps,