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
934f08c5
Commit
934f08c5
authored
Dec 30, 2003
by
jani@rhols221.adsl.netsonic.fi
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fixed Bug#1472, mysql \h output out of order.
parent
210a8750
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
6 deletions
+9
-6
client/mysql.cc
client/mysql.cc
+9
-6
No files found.
client/mysql.cc
View file @
934f08c5
...
@@ -227,11 +227,12 @@ typedef struct {
...
@@ -227,11 +227,12 @@ typedef struct {
}
COMMANDS
;
}
COMMANDS
;
static
COMMANDS
commands
[]
=
{
static
COMMANDS
commands
[]
=
{
{
"help"
,
'h'
,
com_help
,
1
,
"Display this help."
},
{
"?"
,
'?'
,
com_help
,
1
,
"Synonym for `help'."
},
{
"?"
,
'?'
,
com_help
,
1
,
"Synonym for `help'."
},
{
"clear"
,
'c'
,
com_clear
,
0
,
"Clear command."
},
{
"clear"
,
'c'
,
com_clear
,
0
,
"Clear command."
},
{
"connect"
,
'r'
,
com_connect
,
1
,
{
"connect"
,
'r'
,
com_connect
,
1
,
"Reconnect to the server. Optional arguments are db and host."
},
"Reconnect to the server. Optional arguments are db and host."
},
{
"delimiter"
,
'd'
,
com_delimiter
,
1
,
"Set query delimiter. "
},
#ifdef USE_POPEN
#ifdef USE_POPEN
{
"edit"
,
'e'
,
com_edit
,
0
,
"Edit command with $EDITOR."
},
{
"edit"
,
'e'
,
com_edit
,
0
,
"Edit command with $EDITOR."
},
#endif
#endif
...
@@ -239,6 +240,7 @@ static COMMANDS commands[] = {
...
@@ -239,6 +240,7 @@ static COMMANDS commands[] = {
"Send command to mysql server, display result vertically."
},
"Send command to mysql server, display result vertically."
},
{
"exit"
,
'q'
,
com_quit
,
0
,
"Exit mysql. Same as quit."
},
{
"exit"
,
'q'
,
com_quit
,
0
,
"Exit mysql. Same as quit."
},
{
"go"
,
'g'
,
com_go
,
0
,
"Send command to mysql server."
},
{
"go"
,
'g'
,
com_go
,
0
,
"Send command to mysql server."
},
{
"help"
,
'h'
,
com_help
,
1
,
"Display this help."
},
#ifdef USE_POPEN
#ifdef USE_POPEN
{
"nopager"
,
'n'
,
com_nopager
,
0
,
"Disable pager, print to stdout."
},
{
"nopager"
,
'n'
,
com_nopager
,
0
,
"Disable pager, print to stdout."
},
#endif
#endif
...
@@ -261,8 +263,6 @@ static COMMANDS commands[] = {
...
@@ -261,8 +263,6 @@ static COMMANDS commands[] = {
"Set outfile [to_outfile]. Append everything into given outfile."
},
"Set outfile [to_outfile]. Append everything into given outfile."
},
{
"use"
,
'u'
,
com_use
,
1
,
{
"use"
,
'u'
,
com_use
,
1
,
"Use another database. Takes database name as argument."
},
"Use another database. Takes database name as argument."
},
{
"delimiter"
,
'd'
,
com_delimiter
,
1
,
"Set query delimiter. "
},
/* Get bash-like expansion for some commands */
/* Get bash-like expansion for some commands */
{
"create table"
,
0
,
0
,
0
,
""
},
{
"create table"
,
0
,
0
,
0
,
""
},
{
"create database"
,
0
,
0
,
0
,
""
},
{
"create database"
,
0
,
0
,
0
,
""
},
...
@@ -1577,8 +1577,8 @@ static int
...
@@ -1577,8 +1577,8 @@ static int
com_help
(
String
*
buffer
__attribute__
((
unused
)),
com_help
(
String
*
buffer
__attribute__
((
unused
)),
char
*
line
__attribute__
((
unused
)))
char
*
line
__attribute__
((
unused
)))
{
{
reg1
int
i
;
reg1
int
i
,
j
;
char
*
help_arg
=
strchr
(
line
,
' '
);
char
*
help_arg
=
strchr
(
line
,
' '
)
,
buff
[
32
],
*
end
;
if
(
help_arg
)
if
(
help_arg
)
return
com_server_help
(
buffer
,
line
,
help_arg
+
1
);
return
com_server_help
(
buffer
,
line
,
help_arg
+
1
);
...
@@ -1591,8 +1591,11 @@ com_help(String *buffer __attribute__((unused)),
...
@@ -1591,8 +1591,11 @@ com_help(String *buffer __attribute__((unused)),
put_info
(
"Note that all text commands must be first on line and end with ';'"
,
INFO_INFO
);
put_info
(
"Note that all text commands must be first on line and end with ';'"
,
INFO_INFO
);
for
(
i
=
0
;
commands
[
i
].
name
;
i
++
)
for
(
i
=
0
;
commands
[
i
].
name
;
i
++
)
{
{
end
=
strmov
(
buff
,
commands
[
i
].
name
);
for
(
j
=
strlen
(
commands
[
i
].
name
);
j
<
10
;
j
++
)
end
=
strmov
(
end
,
" "
);
if
(
commands
[
i
].
func
)
if
(
commands
[
i
].
func
)
tee_fprintf
(
stdout
,
"%s
\t
(
\\
%c)
\t
%s
\n
"
,
commands
[
i
].
name
,
tee_fprintf
(
stdout
,
"%s
(
\\
%c) %s
\n
"
,
buff
,
commands
[
i
].
cmd_char
,
commands
[
i
].
doc
);
commands
[
i
].
cmd_char
,
commands
[
i
].
doc
);
}
}
if
(
connected
&&
mysql_get_server_version
(
&
mysql
)
>=
40100
)
if
(
connected
&&
mysql_get_server_version
(
&
mysql
)
>=
40100
)
...
...
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