mirror of
https://github.com/MariaDB/server.git
synced 2026-05-16 20:07:13 +02:00
Merge paul@work.mysql.com:/home/bk/mysql-4.0
into teton.kitebird.com:/home/paul/mysql-4.0 Docs/manual.texi: Auto merged
This commit is contained in:
commit
ea280b71c7
6 changed files with 46 additions and 11 deletions
|
|
@ -12,7 +12,7 @@ GetOptions("Information","help","distribution=s","user=s","result=s","delete","n
|
|||
usage() if ($opt_help || $opt_Information);
|
||||
usage() if (!$opt_distribution);
|
||||
|
||||
if (($opt_innodb || $opt_bdb) && $opt_version_suffix eq "")
|
||||
if ($opt_bdb && $opt_version_suffix eq "")
|
||||
{
|
||||
$opt_version_suffix="-max";
|
||||
}
|
||||
|
|
|
|||
|
|
@ -19815,7 +19815,7 @@ MyISAM uses special tree-like cache to make bulk inserts (that is,
|
|||
@code{INSERT ... SELECT}, @code{INSERT ... VALUES (...), (...), ...}, and
|
||||
@code{LOAD DATA INFILE}) faster. This variable limits
|
||||
the size of the cache tree in bytes per thread. Setting it to 0
|
||||
will disable this optimization.
|
||||
will disable this optimisation.
|
||||
@strong{Note}: this cache is only used when adding data to non-empty table.
|
||||
Default value is 8 MB.
|
||||
|
||||
|
|
@ -20324,7 +20324,7 @@ example an @code{ALTER TABLE} or a @code{LOCK TABLE} can prevent opening
|
|||
a table until the command is finished.
|
||||
@item @code{Removing duplicates}
|
||||
The query was using @code{SELECT DISTINCT} in such a way that MySQL
|
||||
couldn't optimize that distinct away at an early stage. Because of this
|
||||
couldn't optimise that distinct away at an early stage. Because of this
|
||||
MySQL has to do an extra stage to remove all duplicated rows before
|
||||
sending the result to the client.
|
||||
@item @code{Reopen table}
|
||||
|
|
@ -26013,7 +26013,7 @@ the sort-key) is written to a result file.
|
|||
@item
|
||||
Now the code in @file{sql/records.cc} will be used to read through them
|
||||
in sorted order by using the row pointers in the result file. To
|
||||
optimize this, we read in a big block of row pointers, sort these and
|
||||
optimise this, we read in a big block of row pointers, sort these and
|
||||
then we read the rows in the sorted order into a row buffer
|
||||
(@code{record_rnd_buffer}) .
|
||||
@end itemize
|
||||
|
|
@ -26163,7 +26163,7 @@ Execute a @code{FLUSH TABLES} statement or the shell command @code{mysqladmin
|
|||
flush-tables}.
|
||||
@end enumerate
|
||||
|
||||
Note that @code{LOAD DATA INFILE} also does the above optimization if
|
||||
Note that @code{LOAD DATA INFILE} also does the above optimisation if
|
||||
you insert into an empty table; the main difference with the above
|
||||
procedure is that you can let myisamchk allocate much more temporary
|
||||
memory for the index creation that you may want MySQL to allocate for
|
||||
|
|
@ -26872,7 +26872,7 @@ In the first statement, the @code{LIKE} value begins with a wildcard
|
|||
character. In the second statement, the @code{LIKE} value is not a
|
||||
constant.
|
||||
|
||||
MySQL 4.0 does another optimization on @code{LIKE}. If you use
|
||||
MySQL 4.0 does another optimisation on @code{LIKE}. If you use
|
||||
@code{... LIKE "%string%"} and @code{string} is longer than 3 characters,
|
||||
MySQL will use the @code{Turbo Boyer-Moore} algorithm to initialise the
|
||||
pattern for the string and then use this pattern to perform the search
|
||||
|
|
@ -34475,13 +34475,13 @@ A designated table handler is allocated for the thread in @code{HANDLER open}.
|
|||
@item
|
||||
There is less parsing involved.
|
||||
@item
|
||||
No optimizer and no query checking overhead.
|
||||
No optimiser and no query checking overhead.
|
||||
@item
|
||||
The used table doesn't have to be locked between two handler requests.
|
||||
@item
|
||||
The handler interface doesn't have to provide a consistent look of the
|
||||
data (for example dirty-reads are allow), which allows the table handler
|
||||
to do optimizations that SQL doesn't normally allow.
|
||||
to do optimisations that SQL doesn't normally allow.
|
||||
@end itemize
|
||||
@item
|
||||
It makes it much easier to port applications that uses an ISAM like
|
||||
|
|
@ -50065,6 +50065,8 @@ Our TODO section contains what we plan to have in 4.0. @xref{TODO MySQL 4.0}.
|
|||
|
||||
@itemize @bullet
|
||||
@item
|
||||
Fixed bug in query cache initialisation with very small query cache size.
|
||||
@item
|
||||
Allow @code{DEFAULT} with @code{INSERT} statement.
|
||||
@item
|
||||
The startup parameters @code{myisam_max_extra_sort_file_size} and
|
||||
|
|
|
|||
|
|
@ -490,3 +490,19 @@ drop table t1;
|
|||
show status like "Qcache_queries_in_cache";
|
||||
Variable_name Value
|
||||
Qcache_queries_in_cache 0
|
||||
set GLOBAL query_cache_size=1000;
|
||||
show global variables like "query_cache_size";
|
||||
Variable_name Value
|
||||
query_cache_size 0
|
||||
set GLOBAL query_cache_size=1100;
|
||||
set GLOBAL query_cache_size=1200;
|
||||
set GLOBAL query_cache_size=1300;
|
||||
set GLOBAL query_cache_size=1400;
|
||||
set GLOBAL query_cache_size=1500;
|
||||
set GLOBAL query_cache_size=1600;
|
||||
set GLOBAL query_cache_size=1700;
|
||||
set GLOBAL query_cache_size=1800;
|
||||
set GLOBAL query_cache_size=1900;
|
||||
show global variables like "query_cache_size";
|
||||
Variable_name Value
|
||||
query_cache_size 1024
|
||||
|
|
|
|||
|
|
@ -336,3 +336,19 @@ select a from t1;
|
|||
show status like "Qcache_queries_in_cache";
|
||||
drop table t1;
|
||||
show status like "Qcache_queries_in_cache";
|
||||
|
||||
#
|
||||
# Test of query cache resizing
|
||||
#
|
||||
set GLOBAL query_cache_size=1000;
|
||||
show global variables like "query_cache_size";
|
||||
set GLOBAL query_cache_size=1100;
|
||||
set GLOBAL query_cache_size=1200;
|
||||
set GLOBAL query_cache_size=1300;
|
||||
set GLOBAL query_cache_size=1400;
|
||||
set GLOBAL query_cache_size=1500;
|
||||
set GLOBAL query_cache_size=1600;
|
||||
set GLOBAL query_cache_size=1700;
|
||||
set GLOBAL query_cache_size=1800;
|
||||
set GLOBAL query_cache_size=1900;
|
||||
show global variables like "query_cache_size";
|
||||
|
|
|
|||
|
|
@ -467,7 +467,7 @@ struct show_var_st init_vars[]= {
|
|||
{sys_read_buff_size.name, (char*) &sys_read_buff_size, SHOW_SYS},
|
||||
{sys_read_rnd_buff_size.name,(char*) &sys_read_rnd_buff_size, SHOW_SYS},
|
||||
{sys_rpl_recovery_rank.name,(char*) &sys_rpl_recovery_rank, SHOW_SYS},
|
||||
#ifdef HAVE_QUERTY_CACHE
|
||||
#ifdef HAVE_QUERY_CACHE
|
||||
{sys_query_cache_limit.name,(char*) &sys_query_cache_limit, SHOW_SYS},
|
||||
{sys_query_cache_size.name, (char*) &sys_query_cache_size, SHOW_SYS},
|
||||
{sys_query_cache_type.name, (char*) &sys_query_cache_type, SHOW_SYS},
|
||||
|
|
|
|||
|
|
@ -1276,10 +1276,11 @@ ulong Query_cache::init_cache()
|
|||
query_cache_size -= additional_data_size;
|
||||
|
||||
STRUCT_LOCK(&structure_guard_mutex);
|
||||
if (query_cache_size <= min_allocation_unit)
|
||||
if (max_mem_bin_size <= min_allocation_unit)
|
||||
{
|
||||
DBUG_PRINT("qcache",
|
||||
(" query_cache_size <= min_allocation_unit => cache disabled"));
|
||||
(" max bin size (%lu) <= min_allocation_unit => cache disabled",
|
||||
max_mem_bin_size));
|
||||
STRUCT_UNLOCK(&structure_guard_mutex);
|
||||
goto err;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue