Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
M
mariadb
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
mariadb
Commits
30c4d10e
Commit
30c4d10e
authored
Jan 13, 2005
by
konstantin@mysql.com
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add logging of COM_EXECUTE in the general query log.
parent
3e3e140e
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
5 additions
and
2 deletions
+5
-2
sql/sql_parse.cc
sql/sql_parse.cc
+1
-1
sql/sql_prepare.cc
sql/sql_prepare.cc
+4
-1
No files found.
sql/sql_parse.cc
View file @
30c4d10e
...
...
@@ -64,7 +64,7 @@ const char *command_name[]={
"Drop DB"
,
"Refresh"
,
"Shutdown"
,
"Statistics"
,
"Processlist"
,
"Connect"
,
"Kill"
,
"Debug"
,
"Ping"
,
"Time"
,
"Delayed insert"
,
"Change user"
,
"Binlog Dump"
,
"Table Dump"
,
"Connect Out"
,
"Register Slave"
,
"Prepare"
,
"
Prepare
Execute"
,
"Long Data"
,
"Close stmt"
,
"Prepare"
,
"Execute"
,
"Long Data"
,
"Close stmt"
,
"Reset stmt"
,
"Set option"
,
"Error"
// Last command number
};
...
...
sql/sql_prepare.cc
View file @
30c4d10e
...
...
@@ -1592,7 +1592,7 @@ int mysql_stmt_prepare(THD *thd, char *packet, uint packet_length,
DBUG_RETURN
(
1
);
}
mysql_log
.
write
(
thd
,
COM_PREPARE
,
"
%s"
,
packet
);
mysql_log
.
write
(
thd
,
COM_PREPARE
,
"
[%lu] %s"
,
stmt
->
id
,
packet
);
thd
->
current_arena
=
stmt
;
mysql_init_query
(
thd
,
(
uchar
*
)
thd
->
query
,
thd
->
query_length
);
...
...
@@ -1792,6 +1792,9 @@ void mysql_stmt_execute(THD *thd, char *packet, uint packet_length)
if
(
stmt
->
param_count
&&
stmt
->
set_params_data
(
stmt
,
&
expanded_query
))
goto
set_params_data_err
;
#endif
mysql_log
.
write
(
thd
,
COM_EXECUTE
,
"[%lu] %s"
,
stmt
->
id
,
expanded_query
.
length
()
?
expanded_query
.
c_ptr
()
:
stmt
->
query
);
thd
->
protocol
=
&
thd
->
protocol_prep
;
// Switch to binary protocol
execute_stmt
(
thd
,
stmt
,
&
expanded_query
,
TRUE
);
thd
->
protocol
=
&
thd
->
protocol_simple
;
// Use normal protocol
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment