I recently found a log statement in my projects codebase that says \"here i am with search parameter==>===========11/30/2008===1====00:00 AM\"
what guidelines do you
The most useful part in a log statement (except maybe the date & time of course) is a unique ID. All our log entries begin with MSG-xxxxx where xxxxx is a unique integer. This MSG-xxxxx tag is always hard-coded in the source, never in a resource file, so it is easy to find it back. It is also a very easy search key in the documentation.
Also what is useful is to always enclose variable string content in double quotes to easily differentiate from the message itself:
MSG-12345 Tried to open "myfile.txt", returned error code "123 - file not found".
This also helps when you try to extract information from the log using some regular expression.