Get queries which is applied on a specific date

  • I want to get all the quries which is applied on a specific date. I will appreciate if u guide me and instruct me step by step.

  • Why are you trying to do something like this?

  • My client report me a bug in my project. But i m sure its not a bug of my project. He/She is manually updating the record. So i want to get all the queries which is applied on a specific date. After see the query i will found out that either its a problem of my project or he/she is manually updating the record.

     

     

  • You'll have to start the profiler and run on trace based on his login. But this will have to run for all the time he's in the office. The trace can be saved to the hd, or server.

    You'll then be able to see what's he running by querying the results. Keep in mind that this can cause serious overhead on the server. This is something you'll have to monitor so it doesn't affect other users.

  • Thanks Remi Greqoire for replying my question. I understand your reply. You mean to say without running profiler we are not able to see the quries. SQL Server does not maintain any log automatically in which it saved the query where we can see the query any time of any day??

  • Yes there's a log in sql server, however this information is stored in hexadecimal format and needs to be interpreted. Also sql server logs only the MODIFICATIONS to the data. If the user only selects it, it won't be logged.

    If you need to scan for those changes, you need to buy a log explorer (don't know any free version). Or start up the profiler and ask him to rerun the part of the program that he thinks is causing the bug.

Viewing 6 posts - 1 through 5 (of 5 total)

You must be logged in to reply to this topic. Login to reply