Is there a way to log all the sql statements that are sent to server. Profiler is capturing the sql and displays the query plan. I looked at sp_trace_<xxxxx> procedures but could not get much info as they are exteneded procedures.

I would really appreciate if somebody have a script that can be run for a given interval and capture the sql code. Thanks a lot.