1. Open SQL Server Management Studio, select Tools->sql Server Profiler, or direct from path: Start/program/microsoft SQL Server R2/performance Tools/sql Server Profiler.
2. After connecting to the database, directly open the tracking new interface, or in the path: file--New tracking under Add tracking, connect to the database
3. Click on the Event Selection page, select the event, tick the columns that need to be displayed so that the columns are displayed when the tracking is made;
4. Just look at the database that the current user needs to view, this uses the column filter function, click on the "Column filter", select the column to be set, enter the condition,
For example, if you look at a database with a database ID of 6,DatabaseID is a unique identifier for each database, the statement select db_id (' _testdbname ') can be queried, and of course the DatabaseName column is filtered. Please set your own for other needs.
You can also set:textdata similar to:%select%t_usertable% so that you can navigate to the table name.
5.
6. OK, run.
Simple use of SQL Server Profiler query tracking