summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMikael Ronstrom <mikael@mysql.com>2009-10-16 17:41:15 +0200
committerMikael Ronstrom <mikael@mysql.com>2009-10-16 17:41:15 +0200
commit29b7a0aadcb9b18258f0286cbd7af7e3143c4148 (patch)
tree2b0be441dab227e906fe718c5524892d2675b6bd
parent975c1ff80801060abb7665f84d899cc0a57c7382 (diff)
downloadmariadb-git-29b7a0aadcb9b18258f0286cbd7af7e3143c4148.tar.gz
Removed GLOBAL INDEX syntax, need to develop GLOBAL indexes before adding syntax for it
-rw-r--r--mysql-test/r/partition_not_windows.result4
-rw-r--r--mysql-test/r/partition_range.result5
-rw-r--r--mysql-test/r/partition_symlink.result4
-rw-r--r--mysql-test/t/partition_range.test6
-rw-r--r--sql/share/errmsg.txt2
-rw-r--r--sql/sql_lex.cc1
-rw-r--r--sql/sql_lex.h3
-rw-r--r--sql/sql_yacc.yy22
8 files changed, 7 insertions, 40 deletions
diff --git a/mysql-test/r/partition_not_windows.result b/mysql-test/r/partition_not_windows.result
index 42dca557b3e..af6e3b5b9e3 100644
--- a/mysql-test/r/partition_not_windows.result
+++ b/mysql-test/r/partition_not_windows.result
@@ -24,8 +24,8 @@ data directory='/not/existing'
index directory='/not/existing'
);
Warnings:
-Warning 1618 <DATA DIRECTORY> option ignored
-Warning 1618 <INDEX DIRECTORY> option ignored
+Warning 1619 <DATA DIRECTORY> option ignored
+Warning 1619 <INDEX DIRECTORY> option ignored
show create table t2;
Table Create Table
t2 CREATE TABLE `t2` (
diff --git a/mysql-test/r/partition_range.result b/mysql-test/r/partition_range.result
index fc15665d698..a3d02b66c0a 100644
--- a/mysql-test/r/partition_range.result
+++ b/mysql-test/r/partition_range.result
@@ -84,11 +84,6 @@ create table t1 (a int, b char(20))
partition by range(a)
(partition p0 values less than (column_list(1,"b")));
ERROR HY000: Inconsistency in usage of column lists for partitioning
-create table t1 (a int, b char(20));
-create global index inx on t1 (a,b)
-partition by range (a)
-(partition p0 values less than (1));
-drop table t1;
create table t1 (a int, b char(20))
partition by range column_list(b)
(partition p0 values less than (column_list("b")));
diff --git a/mysql-test/r/partition_symlink.result b/mysql-test/r/partition_symlink.result
index 60184d11d9c..7d3e220a211 100644
--- a/mysql-test/r/partition_symlink.result
+++ b/mysql-test/r/partition_symlink.result
@@ -101,8 +101,8 @@ data directory='/not/existing'
index directory='/not/existing'
);
Warnings:
-Warning 1618 <DATA DIRECTORY> option ignored
-Warning 1618 <INDEX DIRECTORY> option ignored
+Warning 1619 <DATA DIRECTORY> option ignored
+Warning 1619 <INDEX DIRECTORY> option ignored
show create table t2;
Table Create Table
t2 CREATE TABLE `t2` (
diff --git a/mysql-test/t/partition_range.test b/mysql-test/t/partition_range.test
index c14dfd1822d..741bae7b3cc 100644
--- a/mysql-test/t/partition_range.test
+++ b/mysql-test/t/partition_range.test
@@ -74,12 +74,6 @@ create table t1 (a int, b char(20))
partition by range(a)
(partition p0 values less than (column_list(1,"b")));
-create table t1 (a int, b char(20));
-create global index inx on t1 (a,b)
-partition by range (a)
-(partition p0 values less than (1));
-drop table t1;
-
create table t1 (a int, b char(20))
partition by range column_list(b)
(partition p0 values less than (column_list("b")));
diff --git a/sql/share/errmsg.txt b/sql/share/errmsg.txt
index 3d228f58360..78eb0e09c11 100644
--- a/sql/share/errmsg.txt
+++ b/sql/share/errmsg.txt
@@ -6182,8 +6182,6 @@ ER_TOO_LONG_FIELD_COMMENT
ER_FUNC_INEXISTENT_NAME_COLLISION 42000
eng "FUNCTION %s does not exist. Check the 'Function Name Parsing and Resolution' section in the Reference Manual"
-ER_GLOBAL_PARTITION_INDEX_ERROR
- eng "Partitioning of indexes only supported for global indexes"
ER_PARTITION_COLUMN_LIST_ERROR
eng "Inconsistency in usage of column lists for partitioning"
ER_WRONG_TYPE_COLUMN_VALUE_ERROR
diff --git a/sql/sql_lex.cc b/sql/sql_lex.cc
index 703a97a6565..9f4e4cbd2ca 100644
--- a/sql/sql_lex.cc
+++ b/sql/sql_lex.cc
@@ -323,7 +323,6 @@ void lex_start(THD *thd)
lex->select_lex.select_number= 1;
lex->length=0;
lex->part_info= 0;
- lex->global_flag= 0;
lex->select_lex.in_sum_expr=0;
lex->select_lex.ftfunc_list_alloc.empty();
lex->select_lex.ftfunc_list= &lex->select_lex.ftfunc_list_alloc;
diff --git a/sql/sql_lex.h b/sql/sql_lex.h
index 3d638689700..d653540a628 100644
--- a/sql/sql_lex.h
+++ b/sql/sql_lex.h
@@ -1565,9 +1565,6 @@ typedef struct st_lex : public Query_tables_list
/* Partition info structure filled in by PARTITION BY parse part */
partition_info *part_info;
- /* Flag to index a global index created */
- bool global_flag;
-
/*
The definer of the object being created (view, trigger, stored routine).
I.e. the value of DEFINER clause.
diff --git a/sql/sql_yacc.yy b/sql/sql_yacc.yy
index 0610350b38f..bb6ea780619 100644
--- a/sql/sql_yacc.yy
+++ b/sql/sql_yacc.yy
@@ -1157,7 +1157,6 @@ bool my_yyoverflow(short **a, YYSTYPE **b, ulong *yystacksize);
opt_natural_language_mode opt_query_expansion
opt_ev_status opt_ev_on_completion ev_on_completion opt_ev_comment
ev_alter_on_schedule_completion opt_ev_rename_to opt_ev_sql_stmt
- opt_global
%type <ulong_num>
ulong_num real_ulong_num merge_insert_types
@@ -1695,12 +1694,12 @@ create:
$5->table.str);
}
}
- | CREATE opt_global opt_unique_or_fulltext INDEX_SYM ident key_alg ON
+ | CREATE opt_unique_or_fulltext INDEX_SYM ident key_alg ON
table_ident
{
LEX *lex=Lex;
lex->sql_command= SQLCOM_CREATE_INDEX;
- if (!lex->current_select->add_table_to_list(lex->thd, $8,
+ if (!lex->current_select->add_table_to_list(lex->thd, $7,
NULL,
TL_OPTION_UPDATING))
MYSQL_YYABORT;
@@ -1708,7 +1707,6 @@ create:
lex->alter_info.flags= ALTER_ADD_INDEX;
lex->col_list.empty();
lex->change=NullS;
- lex->global_flag= $2;
}
'(' key_list ')' key_options
{
@@ -1719,22 +1717,13 @@ create:
my_parse_error(ER(ER_SYNTAX_ERROR));
MYSQL_YYABORT;
}
- key= new Key($3, $5.str, &lex->key_create_info, 0,
+ key= new Key($2, $4.str, &lex->key_create_info, 0,
lex->col_list);
if (key == NULL)
MYSQL_YYABORT;
lex->alter_info.key_list.push_back(key);
lex->col_list.empty();
}
- opt_partitioning
- {
- LEX *lex= Lex;
- if (!lex->global_flag && lex->part_info)
- {
- my_error(ER_GLOBAL_PARTITION_INDEX_ERROR, MYF(0));
- YYABORT;
- }
- }
| CREATE DATABASE opt_if_not_exists ident
{
Lex->create_info.default_table_charset= NULL;
@@ -4454,11 +4443,6 @@ opt_part_option:
{ Lex->part_info->curr_part_elem->part_comment= $3.str; }
;
-opt_global:
- /* empty */ { $$= FALSE;}
- | GLOBAL_SYM { $$= TRUE; }
- ;
-
/*
End of partition parser part
*/