zoukankan      html  css  js  c++  java
  • 用MySQL log调试程序

    打开my.ini文件

    [mysqld]的下面加上
    log = c:/mysql_query.log.txt
    重启mysql

    以后你用可以用editplus查看你运行的sql了,不用在程序里一句句的用log打出来了.

    附:Mysql Doc:
    http://dev.mysql.com/doc/mysql/en/Log_Files.html

    Log File Types of Information Logged to File
    The error log Logs problems encountered starting, running, or stopping mysqld.
    The isam log Logs all changes to the ISAM tables. Used only for debugging the isam code.
    The query log Logs established client connections and executed statements.
    The update log Logs statements that change data. This log is deprecated.
    The binary log Logs all statements that change data. Also used for replication.
    The slow log Logs all queries that took more than long_query_time seconds to execute or didn't use indexes.
  • 相关阅读:
    [solr]
    [solr]
    [Linux] CentOS 加入开机启动
    [Linux] VirtualBox
    [Eclipse]
    [JBoss]
    [solr]
    [solr]
    [solr]
    [solr]
  • 原文地址:https://www.cnblogs.com/wawahaha/p/4849290.html
Copyright © 2011-2022 走看看