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
133651d6
Commit
133651d6
authored
Mar 26, 2002
by
monty@hundin.mysql.fi
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fixed myslqdumpslow for new log format.
parent
beedaf26
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
3 deletions
+7
-3
scripts/mysqldumpslow.sh
scripts/mysqldumpslow.sh
+7
-3
No files found.
scripts/mysqldumpslow.sh
View file @
133651d6
...
...
@@ -75,7 +75,7 @@ while ( defined($_ = shift @pending) or defined($_ = <>) ) {
s/^#? Time:
\d
{
6
}
\s
+
\d
+:
\d
+:
\d
+.
*
\n
//
;
my
(
$user
,
$host
)
=
s/^#? User
\@
Host:
\s
+
(
\S
+
)
\s
+
\@\s
+
(
\S
+
)
.
*
\n
// ?
(
$1
,
$2
)
:
(
''
,
''
)
;
s/^#
T
ime:
(
\d
+
)
Lock_time:
(
\d
+
)
Rows_sent:
(
\d
+
)
.
*
\n
//
;
s/^#
Query_t
ime:
(
\d
+
)
Lock_time:
(
\d
+
)
Rows_sent:
(
\d
+
)
.
*
\n
//
;
my
(
$t
,
$l
,
$r
)
=
(
$1
,
$2
,
$3
)
;
$t
-
=
$l
unless
$opt
{
l
}
;
...
...
@@ -96,8 +96,12 @@ while ( defined($_ = shift @pending) or defined($_ = <>) ) {
unless
(
$opt
{
a
})
{
s/
\b\d
+
\b
/N/g
;
s/
\b
0x[0-9A-Fa-f]+
\b
/N/g
;
s/
'([^\\\'
]
|
\\
.|
\'\'
)
+
'/'
S
'/g;
s/"([^\\\"]|\\.|\"\")+"/"S"/g;
s/
''
/
'S'
/g
;
s/
""
/
"S"
/g
;
s/
(
\\
')//g;
s/(\\")//g;
s/'
[
^
']+'
/
'S'
/g
;
s/
"[^"
]
+
"/"
S
"/g;
# -n=8: turn log_20001231 into log_NNNNNNNN
s/([a-z_]+)(
\d
{
$opt
{n},})/
$1
.('N' x length(
$2
))/ieg if
$opt
{n};
# abbreviate massive "
in
(
...
)
" statements and similar
...
...
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