Add log for tracing session sqls

This commit is contained in:
wangbin579 2018-08-07 12:17:13 +08:00
parent f1ed38e030
commit 810828350c

View File

@ -1142,6 +1142,9 @@ process_query_or_stmt_prepare(network_mysqld_con *con, proxy_plugin_con_t *st,
sql_context_t *context = st->sql_context;
sql_context_parse_len(context, con->orig_sql);
g_debug("%s process query:%s", G_STRLOC, con->orig_sql->str);
if (context->rc == PARSE_SYNTAX_ERR) {
char *msg = context->message;
g_message("%s SQL syntax error: %s. while parsing: %s", G_STRLOC, msg, con->orig_sql->str);