简体   繁体   中英

How do I store recent searches in database?

How do I store recent queries in a database?? I know how to find recent searches which is inserted/modified the database but if it isn't inserted/modified then how do I find recent queries???

You will want to enable MySQL's General Query Log . Taken directly from the site:

The general query log is a general record of what mysqld is doing. The server writes information to this log when clients connect or disconnect, and it logs each SQL statement received from clients.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM