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
bd916a7b
Commit
bd916a7b
authored
Aug 29, 2001
by
unknown
Browse files
Options
Browse Files
Download
Plain Diff
Merge work:/home/bk/mysql into hundin.mysql.fi:/my/bk/mysql
parents
cab5a132
f387d79b
Changes
27
Hide whitespace changes
Inline
Side-by-side
Showing
27 changed files
with
71 additions
and
19 deletions
+71
-19
Docs/manual.texi
Docs/manual.texi
+32
-8
include/mysqld_error.h
include/mysqld_error.h
+2
-1
mysql-test/t/merge.test
mysql-test/t/merge.test
+5
-1
sql/gen_lex_hash.cc
sql/gen_lex_hash.cc
+1
-1
sql/ha_myisammrg.cc
sql/ha_myisammrg.cc
+0
-6
sql/share/czech/errmsg.txt
sql/share/czech/errmsg.txt
+1
-0
sql/share/danish/errmsg.txt
sql/share/danish/errmsg.txt
+1
-0
sql/share/dutch/errmsg.txt
sql/share/dutch/errmsg.txt
+1
-0
sql/share/english/errmsg.txt
sql/share/english/errmsg.txt
+1
-0
sql/share/estonian/errmsg.txt
sql/share/estonian/errmsg.txt
+1
-0
sql/share/french/errmsg.txt
sql/share/french/errmsg.txt
+1
-0
sql/share/german/errmsg.txt
sql/share/german/errmsg.txt
+1
-0
sql/share/greek/errmsg.txt
sql/share/greek/errmsg.txt
+1
-0
sql/share/hungarian/errmsg.txt
sql/share/hungarian/errmsg.txt
+1
-0
sql/share/italian/errmsg.txt
sql/share/italian/errmsg.txt
+1
-0
sql/share/japanese/errmsg.txt
sql/share/japanese/errmsg.txt
+1
-0
sql/share/korean/errmsg.txt
sql/share/korean/errmsg.txt
+1
-0
sql/share/norwegian-ny/errmsg.txt
sql/share/norwegian-ny/errmsg.txt
+1
-0
sql/share/norwegian/errmsg.txt
sql/share/norwegian/errmsg.txt
+1
-0
sql/share/polish/errmsg.txt
sql/share/polish/errmsg.txt
+1
-0
sql/share/portuguese/errmsg.txt
sql/share/portuguese/errmsg.txt
+1
-0
sql/share/romanian/errmsg.txt
sql/share/romanian/errmsg.txt
+1
-0
sql/share/russian/errmsg.txt
sql/share/russian/errmsg.txt
+1
-0
sql/share/slovak/errmsg.txt
sql/share/slovak/errmsg.txt
+1
-0
sql/share/spanish/errmsg.txt
sql/share/spanish/errmsg.txt
+1
-0
sql/share/swedish/errmsg.txt
sql/share/swedish/errmsg.txt
+1
-0
sql/sql_parse.cc
sql/sql_parse.cc
+10
-2
No files found.
Docs/manual.texi
View file @
bd916a7b
...
...
@@ -4502,6 +4502,13 @@ Minimum respective maximum possible @code{double} value.
@item
@code{LIMIT} on negative numbers are treated as big positive numbers.
@item
If you use @code{ALTER TABLE} to first add an @code{UNIQUE} index to a
table used in a @code{MERGE} table and then use @code{ALTER TABLE} to
add a normal index on the @code{MERGE} table, the key order will be
different for the tables if there was an old not-unique key in the
table. This is because @code{ALTER TABLE} puts @code{UNIQUE} keys before
normal keys to be able to detect duplicate keys as early as possible.
@end itemize
The following are known bugs in earlier versions of MySQL:
...
...
@@ -11688,9 +11695,9 @@ work:
@example
CC="cc -pthread"
CFLAGS="-O4 -ansi_alias -ansi_args -fast -inline speed
-speculate
all -arch host"
CFLAGS="-O4 -ansi_alias -ansi_args -fast -inline speed all -arch host"
CXX="cxx -pthread"
CXXFLAGS="-O4 -ansi_alias -ansi_args -fast -inline speed
-speculate
all -arch host"
CXXFLAGS="-O4 -ansi_alias -ansi_args -fast -inline speed all -arch host"
export CC CFLAGS CXX CXXFLAGS
./configure \
--prefix=/usr/local/mysql \
...
...
@@ -34149,6 +34156,12 @@ index exists, it drops the first @code{UNIQUE} index in the table.
(MySQL marks the first @code{UNIQUE} key as the @code{PRIMARY KEY}
if no @code{PRIMARY KEY} was specified explicitly.)
@findex UNIQUE
@findex PRIMARY KEY
If you add a @code{UNIQUE INDEX} or @code{PRIMARY KEY} to a table, this
is stored before any not @code[UNIQUE} index so that MySQL can detect
duplicate keys as early as possible.
@findex ORDER BY
@item
@code{ORDER BY} allows you to create the new table with the rows in a
...
...
@@ -35558,14 +35571,15 @@ mapped tables. (We plan to fix this in 4.0).
With identical tables we mean that all tables are created with identical
column and key information. You can't put a MERGE over tables where the
columns are packed differently
or doesn't have exactly the same columns.
Some of the tables can however be compressed with @code{myisampack}.
@xref{myisampack}.
columns are packed differently
, doesn't have exactly the same columns or
have the keys in different order. Some of the tables can however be
compressed with @code{myisampack}.
@xref{myisampack}.
When you create a @code{MERGE} table, you will get a @code{.frm} table
definition file and a @code{.MRG} table list file. The @code{.MRG} just
contains a list of the index files (@code{.MYI} files) that should
be used as one.
be used as one. All used tables must be in the same database as the
@code{MERGE} table itself.
For the moment you need to have @code{SELECT}, @code{UPDATE}, and
@code{DELETE} privileges on the tables you map to a @code{MERGE} table.
...
...
@@ -35691,7 +35705,6 @@ Change the @code{.MRG} file and issue a @code{FLUSH TABLE} on the
read the new definition file.
@end itemize
@node ISAM, HEAP, MERGE, Table types
@section ISAM Tables
...
...
@@ -46683,17 +46696,28 @@ not yet 100% confident in this code.
@appendixsubsec Changes in release 3.23.42
@itemize @bullet
@item
Enforce that all tables in a @code{MERGE} table comes from the same
database.
@item
Fixed bug with @code{LOAD DATA INFILE} and transactional tables.
@item
Fix bug when using @code{INSERT DELAYED} with wrong column definition.
@item
Fixed coredump during REPAIR of some particulary broken tables.
@item
Fixed bug in @code{InnoDB} and @code{AUTO_INCREMENT} columns.
@item
Fixed critical bug in @code{InnoDB} and @code{BLOB}'s. If one has used
@code{BLOB}'s larger than 8K in an @code{InnoDB} table one must dump
the table with @code{mysqldump}, drop it and restore it from the dump.
@item
Applied large patch for OS/2 from Yuri Dario.
@item
Fixed problem with InnoDB when one could get the error @code{Can't
execute the given command...} even when one didn't have an active
transaction.
@item
Applied some
fixes for
Gemini.
Applied some
minor fixes that concerns
Gemini.
@item
Use real arithmetic operations even in integer context if not
all arguments are integers. (Fixes uncommon bug in some integer
include/mysqld_error.h
View file @
bd916a7b
...
...
@@ -212,4 +212,5 @@
#define ER_CREATE_DB_WITH_READ_LOCK 1209
#define ER_WRONG_ARGUMENTS 1210
#define ER_NO_PERMISSON_TO_CREATE_USER 1211
#define ER_ERROR_MESSAGES 212
#define ER_UNION_TABLES_IN_DIFFERENT_DIR 1212
#define ER_ERROR_MESSAGES 213
mysql-test/t/merge.test
View file @
bd916a7b
...
...
@@ -35,9 +35,13 @@ show create table t3;
# The following should give errors
create
table
t4
(
a
int
not
null
,
b
char
(
10
),
key
(
a
))
type
=
MERGE
UNION
=
(
t1
,
t2
);
--
error
1016
select
*
from
t4
;
--
error
1212
create
table
t5
(
a
int
not
null
,
b
char
(
10
),
key
(
a
))
type
=
MERGE
UNION
=
(
test
.
t1
,
test_2
.
t2
);
# Because of windows, it's important that we drop the merge tables first!
drop
table
if
exists
t4
,
t3
,
t1
,
t2
;
drop
table
if
exists
t
5
,
t
4
,
t3
,
t1
,
t2
;
create
table
t1
(
c
char
(
10
))
type
=
myisam
;
create
table
t2
(
c
char
(
10
))
type
=
myisam
;
...
...
sql/gen_lex_hash.cc
View file @
bd916a7b
...
...
@@ -472,7 +472,7 @@ int main(int argc,char **argv)
int
error
;
MY_INIT
(
argv
[
0
]);
start_value
=
4597269L
;
best_t1
=
6001982L
;
best_t2
=
5063828L
;
best_type
=
4
;
/* mode=4513 add=8
type: 0 */
start_value
=
6130115L
;
best_t1
=
3632784L
;
best_t2
=
86437L
;
best_type
=
3
;
/* mode=4229 add=2
type: 0 */
if
(
get_options
(
argc
,(
char
**
)
argv
))
exit
(
1
);
...
...
sql/ha_myisammrg.cc
View file @
bd916a7b
...
...
@@ -86,7 +86,6 @@ int ha_myisammrg::delete_row(const byte * buf)
int
ha_myisammrg
::
index_read
(
byte
*
buf
,
const
byte
*
key
,
uint
key_len
,
enum
ha_rkey_function
find_flag
)
{
// return (my_errno=HA_ERR_WRONG_COMMAND);
statistic_increment
(
ha_read_key_count
,
&
LOCK_status
);
int
error
=
myrg_rkey
(
file
,
buf
,
active_index
,
key
,
key_len
,
find_flag
);
table
->
status
=
error
?
STATUS_NOT_FOUND
:
0
;
...
...
@@ -96,7 +95,6 @@ int ha_myisammrg::index_read(byte * buf, const byte * key,
int
ha_myisammrg
::
index_read_idx
(
byte
*
buf
,
uint
index
,
const
byte
*
key
,
uint
key_len
,
enum
ha_rkey_function
find_flag
)
{
// return (my_errno=HA_ERR_WRONG_COMMAND);
statistic_increment
(
ha_read_key_count
,
&
LOCK_status
);
int
error
=
myrg_rkey
(
file
,
buf
,
index
,
key
,
key_len
,
find_flag
);
table
->
status
=
error
?
STATUS_NOT_FOUND
:
0
;
...
...
@@ -105,7 +103,6 @@ int ha_myisammrg::index_read_idx(byte * buf, uint index, const byte * key,
int
ha_myisammrg
::
index_next
(
byte
*
buf
)
{
// return (my_errno=HA_ERR_WRONG_COMMAND);
statistic_increment
(
ha_read_next_count
,
&
LOCK_status
);
int
error
=
myrg_rnext
(
file
,
buf
,
active_index
);
table
->
status
=
error
?
STATUS_NOT_FOUND
:
0
;
...
...
@@ -114,7 +111,6 @@ int ha_myisammrg::index_next(byte * buf)
int
ha_myisammrg
::
index_prev
(
byte
*
buf
)
{
// return (my_errno=HA_ERR_WRONG_COMMAND);
statistic_increment
(
ha_read_prev_count
,
&
LOCK_status
);
int
error
=
myrg_rprev
(
file
,
buf
,
active_index
);
table
->
status
=
error
?
STATUS_NOT_FOUND
:
0
;
...
...
@@ -123,7 +119,6 @@ int ha_myisammrg::index_prev(byte * buf)
int
ha_myisammrg
::
index_first
(
byte
*
buf
)
{
// return (my_errno=HA_ERR_WRONG_COMMAND);
statistic_increment
(
ha_read_first_count
,
&
LOCK_status
);
int
error
=
myrg_rfirst
(
file
,
buf
,
active_index
);
table
->
status
=
error
?
STATUS_NOT_FOUND
:
0
;
...
...
@@ -132,7 +127,6 @@ int ha_myisammrg::index_first(byte * buf)
int
ha_myisammrg
::
index_last
(
byte
*
buf
)
{
// return (my_errno=HA_ERR_WRONG_COMMAND);
statistic_increment
(
ha_read_last_count
,
&
LOCK_status
);
int
error
=
myrg_rlast
(
file
,
buf
,
active_index
);
table
->
status
=
error
?
STATUS_NOT_FOUND
:
0
;
...
...
sql/share/czech/errmsg.txt
View file @
bd916a7b
...
...
@@ -222,3 +222,4 @@
"CREATE DATABASE not allowed while thread is holding global read lock",
"Wrong arguments to %s",
"%-.32s@%-.64s is not allowed to create new users",
"Incorrect table definition; All MERGE tables must be in the same database",
sql/share/danish/errmsg.txt
View file @
bd916a7b
...
...
@@ -216,3 +216,4 @@
"CREATE DATABASE er ikke tilladt mens en tråd holder på globalt read lock",
"Wrong arguments to %s",
"%-.32s@%-.64s is not allowed to create new users",
"Incorrect table definition; All MERGE tables must be in the same database",
sql/share/dutch/errmsg.txt
View file @
bd916a7b
...
...
@@ -217,3 +217,4 @@
"CREATE DATABASE niet toegestaan terwijl thread een globale 'read lock' bezit",
"Foutieve parameters voor %s",
"%-.32s@%-.64s is not allowed to create new users",
"Incorrect table definition; All MERGE tables must be in the same database",
sql/share/english/errmsg.txt
View file @
bd916a7b
...
...
@@ -213,3 +213,4 @@
"CREATE DATABASE not allowed while thread is holding global read lock",
"Wrong arguments to %s",
"%-.32s@%-.64s is not allowed to create new users",
"Incorrect table definition; All MERGE tables must be in the same database",
sql/share/estonian/errmsg.txt
View file @
bd916a7b
...
...
@@ -217,3 +217,4 @@
"CREATE DATABASE not allowed while thread is holding global read lock",
"Wrong arguments to %s",
"%-.32s@%-.64s is not allowed to create new users",
"Incorrect table definition; All MERGE tables must be in the same database",
sql/share/french/errmsg.txt
View file @
bd916a7b
...
...
@@ -213,3 +213,4 @@
"CREATE DATABASE not allowed while thread is holding global read lock",
"Wrong arguments to %s",
"%-.32s@%-.64s is not allowed to create new users",
"Incorrect table definition; All MERGE tables must be in the same database",
sql/share/german/errmsg.txt
View file @
bd916a7b
...
...
@@ -216,3 +216,4 @@
"CREATE DATABASE not allowed while thread is holding global read lock",
"Wrong arguments to %s",
"%-.32s@%-.64s is not allowed to create new users",
"Incorrect table definition; All MERGE tables must be in the same database",
sql/share/greek/errmsg.txt
View file @
bd916a7b
...
...
@@ -213,3 +213,4 @@
"CREATE DATABASE not allowed while thread is holding global read lock",
"Wrong arguments to %s",
"%-.32s@%-.64s is not allowed to create new users",
"Incorrect table definition; All MERGE tables must be in the same database",
sql/share/hungarian/errmsg.txt
View file @
bd916a7b
...
...
@@ -215,3 +215,4 @@
"CREATE DATABASE not allowed while thread is holding global read lock",
"Wrong arguments to %s",
"%-.32s@%-.64s is not allowed to create new users",
"Incorrect table definition; All MERGE tables must be in the same database",
sql/share/italian/errmsg.txt
View file @
bd916a7b
...
...
@@ -213,3 +213,4 @@
"CREATE DATABASE not allowed while thread is holding global read lock",
"Wrong arguments to %s",
"%-.32s@%-.64s is not allowed to create new users",
"Incorrect table definition; All MERGE tables must be in the same database",
sql/share/japanese/errmsg.txt
View file @
bd916a7b
...
...
@@ -215,3 +215,4 @@
"CREATE DATABASE not allowed while thread is holding global read lock",
"Wrong arguments to %s",
"%-.32s@%-.64s is not allowed to create new users",
"Incorrect table definition; All MERGE tables must be in the same database",
sql/share/korean/errmsg.txt
View file @
bd916a7b
...
...
@@ -213,3 +213,4 @@
"CREATE DATABASE not allowed while thread is holding global read lock",
"Wrong arguments to %s",
"%-.32s@%-.64s is not allowed to create new users",
"Incorrect table definition; All MERGE tables must be in the same database",
sql/share/norwegian-ny/errmsg.txt
View file @
bd916a7b
...
...
@@ -215,3 +215,4 @@
"CREATE DATABASE not allowed while thread is holding global read lock",
"Wrong arguments to %s",
"%-.32s@%-.64s is not allowed to create new users",
"Incorrect table definition; All MERGE tables must be in the same database",
sql/share/norwegian/errmsg.txt
View file @
bd916a7b
...
...
@@ -215,3 +215,4 @@
"CREATE DATABASE not allowed while thread is holding global read lock",
"Wrong arguments to %s",
"%-.32s@%-.64s is not allowed to create new users",
"Incorrect table definition; All MERGE tables must be in the same database",
sql/share/polish/errmsg.txt
View file @
bd916a7b
...
...
@@ -217,3 +217,4 @@
"CREATE DATABASE not allowed while thread is holding global read lock",
"Wrong arguments to %s",
"%-.32s@%-.64s is not allowed to create new users",
"Incorrect table definition; All MERGE tables must be in the same database",
sql/share/portuguese/errmsg.txt
View file @
bd916a7b
...
...
@@ -213,3 +213,4 @@
"CREATE DATABASE não permitido enquanto uma 'thread' está mantendo um travamento global de leitura",
"Argumentos errados para %s",
"Não é permitido a %-.32s@%-.64s criar novos usuários",
"Incorrect table definition; All MERGE tables must be in the same database",
sql/share/romanian/errmsg.txt
View file @
bd916a7b
...
...
@@ -217,3 +217,4 @@
"CREATE DATABASE not allowed while thread is holding global read lock",
"Wrong arguments to %s",
"%-.32s@%-.64s is not allowed to create new users",
"Incorrect table definition; All MERGE tables must be in the same database",
sql/share/russian/errmsg.txt
View file @
bd916a7b
...
...
@@ -216,3 +216,4 @@
"CREATE DATABASE not allowed while thread is holding global read lock",
"Wrong arguments to %s",
"%-.32s@%-.64s is not allowed to create new users",
"Incorrect table definition; All MERGE tables must be in the same database",
sql/share/slovak/errmsg.txt
View file @
bd916a7b
...
...
@@ -221,3 +221,4 @@
"CREATE DATABASE not allowed while thread is holding global read lock",
"Wrong arguments to %s",
"%-.32s@%-.64s is not allowed to create new users",
"Incorrect table definition; All MERGE tables must be in the same database",
sql/share/spanish/errmsg.txt
View file @
bd916a7b
...
...
@@ -214,3 +214,4 @@
"CREATE DATABASE no permitido mientras un thread está ejerciendo un bloqueo de lectura global",
"Wrong arguments to %s",
"%-.32s@%-.64s is not allowed to create new users",
"Incorrect table definition; All MERGE tables must be in the same database",
sql/share/swedish/errmsg.txt
View file @
bd916a7b
...
...
@@ -213,3 +213,4 @@
"CREATE DATABASE är inte tillåtet när man har ett globalt läs-lås",
"Felaktiga argument till %s",
"%-.32s@%-.64s har inte rättigheter att skapa nya användare",
"Felaktig tabell definition: Alla tabeller i en MERGE tabell måste vara i samma databas",
sql/sql_parse.cc
View file @
bd916a7b
...
...
@@ -2178,10 +2178,18 @@ static bool check_merge_table_access(THD *thd, char *db,
int
error
=
0
;
if
(
table_list
)
{
/*
Force all tables to
use the current database */
/*
Check that all tables
use the current database */
TABLE_LIST
*
tmp
;
for
(
tmp
=
table_list
;
tmp
;
tmp
=
tmp
->
next
)
tmp
->
db
=
db
;
{
if
(
!
tmp
->
db
||
!
tmp
->
db
[
0
])
tmp
->
db
=
db
;
else
if
(
!
strcmp
(
tmp
->
db
,
db
))
{
send_error
(
&
thd
->
net
,
ER_UNION_TABLES_IN_DIFFERENT_DIR
);
return
1
;
}
}
error
=
check_table_access
(
thd
,
SELECT_ACL
|
UPDATE_ACL
|
DELETE_ACL
,
table_list
);
}
...
...
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