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
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
nexedi
MariaDB
Commits
af898aec
Commit
af898aec
authored
Apr 11, 2006
by
mskold@mysql.com
Browse files
Options
Browse Files
Download
Plain Diff
Merge mskold@bk-internal.mysql.com:/home/bk/mysql-5.1-new
into mysql.com:/usr/local/home/marty/MySQL/mysql-5.1-new
parents
196bcbf7
fae02215
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
65 additions
and
75 deletions
+65
-75
mysql-test/t/ndb_basic.test
mysql-test/t/ndb_basic.test
+0
-11
sql/field.cc
sql/field.cc
+5
-5
sql/ha_ndbcluster_binlog.cc
sql/ha_ndbcluster_binlog.cc
+60
-59
No files found.
mysql-test/t/ndb_basic.test
View file @
af898aec
...
@@ -6,17 +6,6 @@ DROP TABLE IF EXISTS t1,t2,t3,t4,t5,t6,t7;
...
@@ -6,17 +6,6 @@ DROP TABLE IF EXISTS t1,t2,t3,t4,t5,t6,t7;
drop
database
if
exists
mysqltest
;
drop
database
if
exists
mysqltest
;
--
enable_warnings
--
enable_warnings
# workaround for bug#16445
# remove to reproduce bug and run tests drom ndb start
# and with ndb_autodiscover disabled
CREATE
TABLE
t1
(
pk1
INT
NOT
NULL
PRIMARY
KEY
,
attr1
INT
NOT
NULL
,
attr2
INT
,
attr3
VARCHAR
(
10
)
)
ENGINE
=
ndbcluster
;
drop
table
t1
;
#
#
# Basic test to show that the NDB
# Basic test to show that the NDB
# table handler is working
# table handler is working
...
...
sql/field.cc
View file @
af898aec
...
@@ -5989,7 +5989,7 @@ int Field_str::store(double nr)
...
@@ -5989,7 +5989,7 @@ int Field_str::store(double nr)
uint
Field
::
is_equal
(
create_field
*
new_field
)
uint
Field
::
is_equal
(
create_field
*
new_field
)
{
{
return
(
new_field
->
sql_type
==
type
());
return
(
new_field
->
sql_type
==
real_
type
());
}
}
...
@@ -6001,7 +6001,7 @@ uint Field_str::is_equal(create_field *new_field)
...
@@ -6001,7 +6001,7 @@ uint Field_str::is_equal(create_field *new_field)
(
flags
&
(
BINCMP_FLAG
|
BINARY_FLAG
))))
(
flags
&
(
BINCMP_FLAG
|
BINARY_FLAG
))))
return
0
;
/* One of the fields is binary and the other one isn't */
return
0
;
/* One of the fields is binary and the other one isn't */
return
((
new_field
->
sql_type
==
type
())
&&
return
((
new_field
->
sql_type
==
real_
type
())
&&
new_field
->
charset
==
field_charset
&&
new_field
->
charset
==
field_charset
&&
new_field
->
length
==
max_length
());
new_field
->
length
==
max_length
());
}
}
...
@@ -6798,7 +6798,7 @@ Field *Field_varstring::new_key_field(MEM_ROOT *root,
...
@@ -6798,7 +6798,7 @@ Field *Field_varstring::new_key_field(MEM_ROOT *root,
uint
Field_varstring
::
is_equal
(
create_field
*
new_field
)
uint
Field_varstring
::
is_equal
(
create_field
*
new_field
)
{
{
if
(
new_field
->
sql_type
==
type
()
&&
if
(
new_field
->
sql_type
==
real_
type
()
&&
new_field
->
charset
==
field_charset
)
new_field
->
charset
==
field_charset
)
{
{
if
(
new_field
->
length
==
max_length
())
if
(
new_field
->
length
==
max_length
())
...
@@ -7957,12 +7957,12 @@ bool Field_num::eq_def(Field *field)
...
@@ -7957,12 +7957,12 @@ bool Field_num::eq_def(Field *field)
uint
Field_num
::
is_equal
(
create_field
*
new_field
)
uint
Field_num
::
is_equal
(
create_field
*
new_field
)
{
{
return
((
new_field
->
sql_type
==
type
())
&&
return
((
new_field
->
sql_type
==
real_
type
())
&&
((
new_field
->
flags
&
UNSIGNED_FLAG
)
==
(
uint
)
(
flags
&
((
new_field
->
flags
&
UNSIGNED_FLAG
)
==
(
uint
)
(
flags
&
UNSIGNED_FLAG
))
&&
UNSIGNED_FLAG
))
&&
((
new_field
->
flags
&
AUTO_INCREMENT_FLAG
)
==
((
new_field
->
flags
&
AUTO_INCREMENT_FLAG
)
==
(
uint
)
(
flags
&
AUTO_INCREMENT_FLAG
))
&&
(
uint
)
(
flags
&
AUTO_INCREMENT_FLAG
))
&&
(
new_field
->
length
>
=
max_length
()));
(
new_field
->
length
<
=
max_length
()));
}
}
...
...
sql/ha_ndbcluster_binlog.cc
View file @
af898aec
...
@@ -1373,6 +1373,9 @@ ndb_handle_schema_change(THD *thd, Ndb *ndb, NdbEventOperation *pOp,
...
@@ -1373,6 +1373,9 @@ ndb_handle_schema_change(THD *thd, Ndb *ndb, NdbEventOperation *pOp,
NDB_SHARE
*
share
)
NDB_SHARE
*
share
)
{
{
DBUG_ENTER
(
"ndb_handle_schema_change"
);
DBUG_ENTER
(
"ndb_handle_schema_change"
);
TABLE
*
table
=
share
->
table
;
TABLE_SHARE
*
table_share
=
table
->
s
;
const
char
*
dbname
=
table_share
->
db
.
str
;
bool
do_close_cached_tables
=
FALSE
;
bool
do_close_cached_tables
=
FALSE
;
bool
is_online_alter_table
=
FALSE
;
bool
is_online_alter_table
=
FALSE
;
bool
is_rename_table
=
FALSE
;
bool
is_rename_table
=
FALSE
;
...
@@ -1392,14 +1395,9 @@ ndb_handle_schema_change(THD *thd, Ndb *ndb, NdbEventOperation *pOp,
...
@@ -1392,14 +1395,9 @@ ndb_handle_schema_change(THD *thd, Ndb *ndb, NdbEventOperation *pOp,
}
}
}
}
if
(
is_remote_change
)
/* includes CLUSTER_FAILURE */
{
TABLE
*
table
=
share
->
table
;
TABLE_SHARE
*
table_share
=
table
->
s
;
const
char
*
dbname
=
table_share
->
db
.
str
;
/*
/*
Invalidate table and all it's indexes
Refresh local dictionary cache by
invalidating table and all it's indexes
*/
*/
ndb
->
setDatabaseName
(
dbname
);
ndb
->
setDatabaseName
(
dbname
);
Thd_ndb
*
thd_ndb
=
get_thd_ndb
(
thd
);
Thd_ndb
*
thd_ndb
=
get_thd_ndb
(
thd
);
...
@@ -1413,7 +1411,11 @@ ndb_handle_schema_change(THD *thd, Ndb *ndb, NdbEventOperation *pOp,
...
@@ -1413,7 +1411,11 @@ ndb_handle_schema_change(THD *thd, Ndb *ndb, NdbEventOperation *pOp,
table_handler
.
invalidate_dictionary_cache
(
TRUE
);
table_handler
.
invalidate_dictionary_cache
(
TRUE
);
thd_ndb
->
ndb
=
old_ndb
;
thd_ndb
->
ndb
=
old_ndb
;
if
(
is_online_alter_table
)
/*
Refresh local frm file and dictionary cache if
remote on-line alter table
*/
if
(
is_remote_change
&&
is_online_alter_table
)
{
{
const
char
*
tabname
=
table_share
->
table_name
.
str
;
const
char
*
tabname
=
table_share
->
table_name
.
str
;
char
key
[
FN_REFLEN
];
char
key
[
FN_REFLEN
];
...
@@ -1457,7 +1459,6 @@ ndb_handle_schema_change(THD *thd, Ndb *ndb, NdbEventOperation *pOp,
...
@@ -1457,7 +1459,6 @@ ndb_handle_schema_change(THD *thd, Ndb *ndb, NdbEventOperation *pOp,
pthread_mutex_unlock
(
&
LOCK_open
);
pthread_mutex_unlock
(
&
LOCK_open
);
}
}
}
}
}
// If only frm was changed continue replicating
// If only frm was changed continue replicating
if
(
is_online_alter_table
)
if
(
is_online_alter_table
)
...
...
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