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
f47fa6a7
Commit
f47fa6a7
authored
Mar 06, 2004
by
paul@ice.snake.net
Browse files
Options
Browse Files
Download
Plain Diff
Merge paul@bk-internal.mysql.com:/home/bk/mysql-4.1
into ice.snake.net:/Volumes/ice2/MySQL/bk/mysql-4.1
parents
72d83155
99cd60a4
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
52 additions
and
64 deletions
+52
-64
client/mysqltest.c
client/mysqltest.c
+7
-7
mysql-test/r/show_check.result
mysql-test/r/show_check.result
+9
-34
mysql-test/t/show_check.test
mysql-test/t/show_check.test
+36
-23
No files found.
client/mysqltest.c
View file @
f47fa6a7
...
@@ -215,8 +215,8 @@ Q_REQUIRE_VERSION,
...
@@ -215,8 +215,8 @@ Q_REQUIRE_VERSION,
Q_ENABLE_WARNINGS
,
Q_DISABLE_WARNINGS
,
Q_ENABLE_WARNINGS
,
Q_DISABLE_WARNINGS
,
Q_ENABLE_INFO
,
Q_DISABLE_INFO
,
Q_ENABLE_INFO
,
Q_DISABLE_INFO
,
Q_EXEC
,
Q_DELIMITER
,
Q_EXEC
,
Q_DELIMITER
,
Q_DISPLAY_VERTICAL_RESULTS
,
Q_DISPLAY_HORI
S
ONTAL_RESULTS
,
Q_DISPLAY_VERTICAL_RESULTS
,
Q_DISPLAY_HORI
Z
ONTAL_RESULTS
,
Q_QUERY_VERTICAL
,
Q_QUERY_HORI
S
ONTAL
,
Q_QUERY_VERTICAL
,
Q_QUERY_HORI
Z
ONTAL
,
Q_UNKNOWN
,
/* Unknown command. */
Q_UNKNOWN
,
/* Unknown command. */
Q_COMMENT
,
/* Comments, ignored. */
Q_COMMENT
,
/* Comments, ignored. */
...
@@ -291,9 +291,9 @@ const char *command_names[]=
...
@@ -291,9 +291,9 @@ const char *command_names[]=
"exec"
,
"exec"
,
"delimiter"
,
"delimiter"
,
"vertical_results"
,
"vertical_results"
,
"hori
s
ontal_results"
,
"hori
z
ontal_results"
,
"query_vertical"
,
"query_vertical"
,
"query_hori
s
ontal"
,
"query_hori
z
ontal"
,
0
0
};
};
...
@@ -2581,7 +2581,7 @@ int main(int argc, char **argv)
...
@@ -2581,7 +2581,7 @@ int main(int argc, char **argv)
delimiter_length
=
strlen
(
delimiter
);
delimiter_length
=
strlen
(
delimiter
);
break
;
break
;
case
Q_DISPLAY_VERTICAL_RESULTS
:
display_result_vertically
=
TRUE
;
break
;
case
Q_DISPLAY_VERTICAL_RESULTS
:
display_result_vertically
=
TRUE
;
break
;
case
Q_DISPLAY_HORI
S
ONTAL_RESULTS
:
case
Q_DISPLAY_HORI
Z
ONTAL_RESULTS
:
display_result_vertically
=
FALSE
;
break
;
display_result_vertically
=
FALSE
;
break
;
case
Q_LET
:
do_let
(
q
);
break
;
case
Q_LET
:
do_let
(
q
);
break
;
case
Q_EVAL_RESULT
:
eval_result
=
1
;
break
;
case
Q_EVAL_RESULT
:
eval_result
=
1
;
break
;
...
@@ -2590,7 +2590,7 @@ int main(int argc, char **argv)
...
@@ -2590,7 +2590,7 @@ int main(int argc, char **argv)
q
->
query
=
q
->
first_argument
;
q
->
query
=
q
->
first_argument
;
/* fall through */
/* fall through */
case
Q_QUERY_VERTICAL
:
case
Q_QUERY_VERTICAL
:
case
Q_QUERY_HORI
S
ONTAL
:
case
Q_QUERY_HORI
Z
ONTAL
:
{
{
my_bool
old_display_result_vertically
=
display_result_vertically
;
my_bool
old_display_result_vertically
=
display_result_vertically
;
if
(
!
q
->
query
[
q
->
first_word_len
])
if
(
!
q
->
query
[
q
->
first_word_len
])
...
@@ -2605,7 +2605,7 @@ int main(int argc, char **argv)
...
@@ -2605,7 +2605,7 @@ int main(int argc, char **argv)
switch
(
q
->
type
)
switch
(
q
->
type
)
{
{
case
Q_QUERY_VERTICAL
:
display_result_vertically
=
TRUE
;
break
;
case
Q_QUERY_VERTICAL
:
display_result_vertically
=
TRUE
;
break
;
case
Q_QUERY_HORI
S
ONTAL
:
display_result_vertically
=
FALSE
;
break
;
case
Q_QUERY_HORI
Z
ONTAL
:
display_result_vertically
=
FALSE
;
break
;
}
}
error
|=
run_query
(
&
cur_con
->
mysql
,
q
,
QUERY_REAP
|
QUERY_SEND
);
error
|=
run_query
(
&
cur_con
->
mysql
,
q
,
QUERY_REAP
|
QUERY_SEND
);
display_result_vertically
=
old_display_result_vertically
;
display_result_vertically
=
old_display_result_vertically
;
...
...
mysql-test/r/show_check.result
View file @
f47fa6a7
...
@@ -265,39 +265,13 @@ c decimal(4,3) YES NULL
...
@@ -265,39 +265,13 @@ c decimal(4,3) YES NULL
d double(4,3) YES NULL
d double(4,3) YES NULL
f float(4,3) YES NULL
f float(4,3) YES NULL
drop table t1;
drop table t1;
SET sql_mode='';
SET @old_sql_mode= @@sql_mode, sql_mode= '';
SET sql_quote_show_create=OFF;
SET @old_sql_quote_show_create= @@sql_quote_show_create, sql_quote_show_create= OFF;
CREATE TABLE ```ab``cd``` (i INT);
CREATE TABLE `a/b` (i INT);
SHOW CREATE TABLE ```ab``cd```;
ERROR 42000: Incorrect table name 'a/b'
Table Create Table
SET sql_mode= 'ANSI_QUOTES';
`ab`cd` CREATE TABLE ```ab``cd``` (
SET sql_mode= '';
i int(11) default NULL
SET sql_quote_show_create= OFF;
) ENGINE=MyISAM DEFAULT CHARSET=latin1
DROP TABLE ```ab``cd```;
CREATE TABLE ```ab````cd``` (i INT);
SHOW CREATE TABLE ```ab````cd```;
Table Create Table
`ab``cd` CREATE TABLE ```ab````cd``` (
i int(11) default NULL
) ENGINE=MyISAM DEFAULT CHARSET=latin1
DROP TABLE ```ab````cd```;
CREATE TABLE ```a` (i INT);
SHOW CREATE TABLE ```a`;
Table Create Table
`a CREATE TABLE ```a` (
i int(11) default NULL
) ENGINE=MyISAM DEFAULT CHARSET=latin1
DROP TABLE ```a`;
SET sql_mode='ANSI_QUOTES';
CREATE TABLE """a" (i INT);
SHOW CREATE TABLE """a";
Table Create Table
"a CREATE TABLE """a" (
i int(11) default NULL
) ENGINE=MyISAM DEFAULT CHARSET=latin1
DROP TABLE """a";
SET sql_mode='';
SET sql_quote_show_create=OFF;
CREATE TABLE t1 (i INT);
CREATE TABLE t1 (i INT);
SHOW CREATE TABLE t1;
SHOW CREATE TABLE t1;
Table Create Table
Table Create Table
...
@@ -312,7 +286,8 @@ table CREATE TABLE `table` (
...
@@ -312,7 +286,8 @@ table CREATE TABLE `table` (
i int(11) default NULL
i int(11) default NULL
) ENGINE=MyISAM DEFAULT CHARSET=latin1
) ENGINE=MyISAM DEFAULT CHARSET=latin1
DROP TABLE `table`;
DROP TABLE `table`;
SET sql_quote_show_create=ON;
SET sql_quote_show_create= @old_sql_quote_show_create;
SET sql_mode= @old_sql_mode;
select @@max_heap_table_size;
select @@max_heap_table_size;
@@max_heap_table_size
@@max_heap_table_size
1047552
1047552
...
...
mysql-test/t/show_check.test
View file @
f47fa6a7
...
@@ -147,31 +147,43 @@ drop table t1;
...
@@ -147,31 +147,43 @@ drop table t1;
# Test for Bug #2593 "SHOW CREATE TABLE doesn't properly double quotes"
# Test for Bug #2593 "SHOW CREATE TABLE doesn't properly double quotes"
#
#
SET
sql_mode
=
''
;
SET
@
old_sql_mode
=
@@
sql_mode
,
sql_mode
=
''
;
SET
sql_quote_show_create
=
OFF
;
SET
@
old_sql_quote_show_create
=
@@
sql_quote_show_create
,
sql_quote_show_create
=
OFF
;
CREATE
TABLE
```ab``cd```
(
i
INT
);
######### hook for WL#1324 #
SHOW
CREATE
TABLE
```ab``cd```
;
--
error
1103
DROP
TABLE
```ab``cd```
;
CREATE
TABLE
`a/b`
(
i
INT
);
# the above test should WORK when WL#1324 is done,
CREATE
TABLE
```ab````cd```
(
i
INT
);
# it should be removed and
SHOW
CREATE
TABLE
```ab````cd```
;
# the following part should be uncommented then
DROP
TABLE
```ab````cd```
;
#########################################################
# begin of part that must be uncommented when WL#1324 is done
CREATE
TABLE
```a`
(
i
INT
);
#########################################################
SHOW
CREATE
TABLE
```a`
;
#CREATE TABLE ```ab``cd``` (i INT);
DROP
TABLE
```a`
;
#SHOW CREATE TABLE ```ab``cd```;
#DROP TABLE ```ab``cd```;
SET
sql_mode
=
'ANSI_QUOTES'
;
#CREATE TABLE ```ab````cd``` (i INT);
CREATE
TABLE
"""a"
(
i
INT
);
#SHOW CREATE TABLE ```ab````cd```;
SHOW
CREATE
TABLE
"""a"
;
#DROP TABLE ```ab````cd```;
DROP
TABLE
"""a"
;
#CREATE TABLE ```a` (i INT);
#SHOW CREATE TABLE ```a`;
#DROP TABLE ```a`;
SET
sql_mode
=
'ANSI_QUOTES'
;
#CREATE TABLE """a" (i INT);
#SHOW CREATE TABLE """a";
#DROP TABLE """a";
#########################################################
# end of part that must be uncommented when WL#1324 is done
#########################################################
# to test quotes around keywords.. :
# to test quotes around keywords.. :
SET
sql_mode
=
''
;
SET
sql_mode
=
''
;
SET
sql_quote_show_create
=
OFF
;
SET
sql_quote_show_create
=
OFF
;
CREATE
TABLE
t1
(
i
INT
);
CREATE
TABLE
t1
(
i
INT
);
SHOW
CREATE
TABLE
t1
;
SHOW
CREATE
TABLE
t1
;
...
@@ -181,7 +193,8 @@ CREATE TABLE `table` (i INT);
...
@@ -181,7 +193,8 @@ CREATE TABLE `table` (i INT);
SHOW
CREATE
TABLE
`table`
;
SHOW
CREATE
TABLE
`table`
;
DROP
TABLE
`table`
;
DROP
TABLE
`table`
;
SET
sql_quote_show_create
=
ON
;
SET
sql_quote_show_create
=
@
old_sql_quote_show_create
;
SET
sql_mode
=
@
old_sql_mode
;
#
#
# Test for bug #2719 "Heap tables status shows wrong or missing data."
# Test for bug #2719 "Heap tables status shows wrong or missing data."
...
...
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