Tracking SQL under SQL Server uses Profiler, and how do you track sql under MySQL?
In fact, the method is very simple, open the MySQL log logs function, by viewing the trace log can be.
Open the MySQL log logging method:
Configuration methods in the Windows environment:
The version I used: Version:5.0.37-community-nt-log (MySQL Community Edition (GPL))
Find My.ini, mine is in the "G:\Program Files (x86) \mysql\mysql Server 5.0" directory,
Locate [mysqld] and add the following:
Log= the path to store the log/my.log
My configuration values:
After you save the file and restart the service, you can find the "mySQL.log" file in the G:\Program files (x86) \mysql\mysql Server 5.0\data directory.
The configuration method under Linux:
Modify the/ETC/MY.CNF, locate [mysqld], and add the following:
Log= the path to store the log/my.log
After the modification, remember to restart the MySQL service Oh.