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
7da16844
Commit
7da16844
authored
Jul 12, 2013
by
Sergei Golubchik
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix the maria suite
sql/handler.h: not "unused" sql/sql_table.cc: move this check where it is in 10.0
parent
8367241d
Changes
6
Show whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
21 additions
and
18 deletions
+21
-18
mysql-test/suite/maria/maria-ucs2.result
mysql-test/suite/maria/maria-ucs2.result
+0
-1
mysql-test/suite/maria/maria3.result
mysql-test/suite/maria/maria3.result
+1
-1
mysql-test/suite/maria/maria3.test
mysql-test/suite/maria/maria3.test
+1
-1
sql/handler.h
sql/handler.h
+0
-1
sql/sql_table.cc
sql/sql_table.cc
+12
-12
storage/maria/ha_maria.cc
storage/maria/ha_maria.cc
+7
-2
No files found.
mysql-test/suite/maria/maria-ucs2.result
View file @
7da16844
...
@@ -17,7 +17,6 @@ test.t1 check status OK
...
@@ -17,7 +17,6 @@ test.t1 check status OK
ALTER TABLE t1 MODIFY a VARCHAR(800) CHARSET `ucs2`;
ALTER TABLE t1 MODIFY a VARCHAR(800) CHARSET `ucs2`;
Warnings:
Warnings:
Warning 1071 Specified key was too long; max key length is 1000 bytes
Warning 1071 Specified key was too long; max key length is 1000 bytes
Warning 1071 Specified key was too long; max key length is 1000 bytes
CHECK TABLE t1;
CHECK TABLE t1;
Table Op Msg_type Msg_text
Table Op Msg_type Msg_text
test.t1 check status OK
test.t1 check status OK
...
...
mysql-test/suite/maria/maria3.result
View file @
7da16844
...
@@ -460,7 +460,7 @@ id f1
...
@@ -460,7 +460,7 @@ id f1
1 test1
1 test1
2 test2
2 test2
drop table t1;
drop table t1;
SET SQL_MODE = '
TRADITIONAL
';
SET SQL_MODE = '';
create table t1 (n int not null primary key auto_increment, c char(1), unique(c));
create table t1 (n int not null primary key auto_increment, c char(1), unique(c));
insert into t1 values(100, "a");
insert into t1 values(100, "a");
insert into t1 values(300, "b");
insert into t1 values(300, "b");
...
...
mysql-test/suite/maria/maria3.test
View file @
7da16844
...
@@ -364,7 +364,7 @@ INSERT IGNORE INTO t1 (f1) VALUES ("test1");
...
@@ -364,7 +364,7 @@ INSERT IGNORE INTO t1 (f1) VALUES ("test1");
INSERT
IGNORE
INTO
t1
(
f1
)
VALUES
(
"test2"
);
INSERT
IGNORE
INTO
t1
(
f1
)
VALUES
(
"test2"
);
SELECT
*
FROM
t1
;
SELECT
*
FROM
t1
;
drop
table
t1
;
drop
table
t1
;
SET
SQL_MODE
=
'
TRADITIONAL
'
;
SET
SQL_MODE
=
''
;
create
table
t1
(
n
int
not
null
primary
key
auto_increment
,
c
char
(
1
),
unique
(
c
));
create
table
t1
(
n
int
not
null
primary
key
auto_increment
,
c
char
(
1
),
unique
(
c
));
insert
into
t1
values
(
100
,
"a"
);
insert
into
t1
values
(
100
,
"a"
);
...
...
sql/handler.h
View file @
7da16844
...
@@ -401,7 +401,6 @@ enum legacy_db_type
...
@@ -401,7 +401,6 @@ enum legacy_db_type
enum
row_type
{
ROW_TYPE_NOT_USED
=-
1
,
ROW_TYPE_DEFAULT
,
ROW_TYPE_FIXED
,
enum
row_type
{
ROW_TYPE_NOT_USED
=-
1
,
ROW_TYPE_DEFAULT
,
ROW_TYPE_FIXED
,
ROW_TYPE_DYNAMIC
,
ROW_TYPE_COMPRESSED
,
ROW_TYPE_DYNAMIC
,
ROW_TYPE_COMPRESSED
,
ROW_TYPE_REDUNDANT
,
ROW_TYPE_COMPACT
,
ROW_TYPE_REDUNDANT
,
ROW_TYPE_COMPACT
,
/** Unused. Reserved for future versions. */
ROW_TYPE_PAGE
};
ROW_TYPE_PAGE
};
/* Specifies data storage format for individual columns */
/* Specifies data storage format for individual columns */
...
...
sql/sql_table.cc
View file @
7da16844
...
@@ -4023,6 +4023,18 @@ mysql_prepare_create_table(THD *thd, HA_CREATE_INFO *create_info,
...
@@ -4023,6 +4023,18 @@ mysql_prepare_create_table(THD *thd, HA_CREATE_INFO *create_info,
}
}
}
}
/* Give warnings for not supported table options */
#if defined(WITH_ARIA_STORAGE_ENGINE)
extern
handlerton
*
maria_hton
;
if
(
file
->
ht
!=
maria_hton
)
#endif
if
(
create_info
->
transactional
)
push_warning_printf
(
thd
,
Sql_condition
::
WARN_LEVEL_WARN
,
ER_ILLEGAL_HA_CREATE_OPTION
,
ER
(
ER_ILLEGAL_HA_CREATE_OPTION
),
file
->
engine_name
()
->
str
,
"TRANSACTIONAL=1"
);
if
(
parse_option_list
(
thd
,
&
create_info
->
option_struct
,
if
(
parse_option_list
(
thd
,
&
create_info
->
option_struct
,
create_info
->
option_list
,
create_info
->
option_list
,
file
->
partition_ht
()
->
table_options
,
FALSE
,
file
->
partition_ht
()
->
table_options
,
FALSE
,
...
@@ -4506,18 +4518,6 @@ bool create_table_impl(THD *thd,
...
@@ -4506,18 +4518,6 @@ bool create_table_impl(THD *thd,
goto
err
;
goto
err
;
}
}
/* Give warnings for not supported table options */
#if defined(WITH_ARIA_STORAGE_ENGINE)
extern
handlerton
*
maria_hton
;
if
(
file
->
ht
!=
maria_hton
)
#endif
if
(
create_info
->
transactional
)
push_warning_printf
(
thd
,
Sql_condition
::
WARN_LEVEL_WARN
,
ER_ILLEGAL_HA_CREATE_OPTION
,
ER
(
ER_ILLEGAL_HA_CREATE_OPTION
),
file
->
engine_name
()
->
str
,
"TRANSACTIONAL=1"
);
if
(
!
internal_tmp_table
&&
!
(
create_info
->
options
&
HA_LEX_CREATE_TMP_TABLE
))
if
(
!
internal_tmp_table
&&
!
(
create_info
->
options
&
HA_LEX_CREATE_TMP_TABLE
))
{
{
char
frm_name
[
FN_REFLEN
+
1
];
char
frm_name
[
FN_REFLEN
+
1
];
...
...
storage/maria/ha_maria.cc
View file @
7da16844
...
@@ -2954,9 +2954,12 @@ void ha_maria::update_create_info(HA_CREATE_INFO *create_info)
...
@@ -2954,9 +2954,12 @@ void ha_maria::update_create_info(HA_CREATE_INFO *create_info)
}
}
create_info
->
data_file_name
=
data_file_name
;
create_info
->
data_file_name
=
data_file_name
;
create_info
->
index_file_name
=
index_file_name
;
create_info
->
index_file_name
=
index_file_name
;
/* We need to restore the row type as Maria can change it */
/*
Keep user-specified row_type for ALTER,
but show the actually used one in SHOW
*/
if
(
create_info
->
row_type
!=
ROW_TYPE_DEFAULT
&&
if
(
create_info
->
row_type
!=
ROW_TYPE_DEFAULT
&&
!
(
create_info
->
used_fields
&
HA_CREATE_USED_ROW_FORMAT
))
!
(
thd_sql_command
(
ha_thd
())
==
SQLCOM_ALTER_TABLE
))
create_info
->
row_type
=
get_row_type
();
create_info
->
row_type
=
get_row_type
();
/*
/*
Show always page checksums, as this can be forced with
Show always page checksums, as this can be forced with
...
@@ -3211,6 +3214,8 @@ bool ha_maria::check_if_incompatible_data(HA_CREATE_INFO *create_info,
...
@@ -3211,6 +3214,8 @@ bool ha_maria::check_if_incompatible_data(HA_CREATE_INFO *create_info,
if
(
create_info
->
auto_increment_value
!=
stats
.
auto_increment_value
||
if
(
create_info
->
auto_increment_value
!=
stats
.
auto_increment_value
||
create_info
->
data_file_name
!=
data_file_name
||
create_info
->
data_file_name
!=
data_file_name
||
create_info
->
index_file_name
!=
index_file_name
||
create_info
->
index_file_name
!=
index_file_name
||
create_info
->
page_checksum
!=
table
->
s
->
page_checksum
||
create_info
->
transactional
!=
table
->
s
->
transactional
||
(
maria_row_type
(
create_info
)
!=
data_file_type
&&
(
maria_row_type
(
create_info
)
!=
data_file_type
&&
create_info
->
row_type
!=
ROW_TYPE_DEFAULT
)
||
create_info
->
row_type
!=
ROW_TYPE_DEFAULT
)
||
table_changes
==
IS_EQUAL_NO
||
table_changes
==
IS_EQUAL_NO
||
...
...
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