Commit graph

119 commits

Author SHA1 Message Date
Kent Boortz
9da00ebec9 Updated/added copyright headers 2011-06-30 17:46:53 +02:00
Kent Boortz
1400d7a2cc Updated/added copyright headers 2011-06-30 17:37:13 +02:00
Mattias Jonsson
7ecc107757 removed a comment according to the review 2010-10-01 15:30:16 +02:00
Mattias Jonsson
e7dc80b807 Bug#50036: Inconsistent errors when using TIMESTAMP columns/expressions
It was hard to understand what the error really meant.

The error checking in partitioning is done in several different
parts during the execution of a query which can make it
hard to return useful errors.

Added a new error for bad VALUES part in the per PARTITION clause.
Using the more verbose error that a column is not allowed in
the partitioning function instead of just that the function is
not allowed.
2010-08-30 17:33:55 +02:00
Davi Arnaut
6c15f6718f Merge of mysql-5.1-bugteam into mysql-trunk-merge. 2010-07-20 16:30:10 -03:00
Davi Arnaut
c96b249fc3 Bug#45288: pb2 returns a lot of compilation warnings on linux
Fix warnings flagged by the new warning option -Wunused-but-set-variable
that was added to GCC 4.6 and that is enabled by -Wunused and -Wall. The
option causes a warning whenever a local variable is assigned to but is
later unused. It also warns about meaningless pointer dereferences.
2010-07-20 15:07:36 -03:00
Davi Arnaut
e1f748c0bd Merge of mysql-5.1-bugteam into mysql-trunk-merge. 2010-07-09 09:28:51 -03:00
Davi Arnaut
ed9ffc6b09 Bug#45288: pb2 returns a lot of compilation warnings on linux
Although the C standard mandates that sprintf return the number
of bytes written, some very ancient systems (i.e. SunOS 4)
returned a pointer to the buffer instead. Since these systems
are not supported anymore and are hopefully long dead by now,
simply remove the portability wrapper that dealt with this
discrepancy. The autoconf check was causing trouble with GCC.
2010-07-09 09:00:17 -03:00
Davi Arnaut
5dec0c9637 Bug#53445: Build with -Wall and fix warnings that it generates
Fix various mismatches between function's language linkage. Any
particular function that is declared in C++ but should be callable
from C must have C linkage. Note that function types with different
linkages are also distinct. Thus, if a function type is declared in
C code, it will have C linkage (same if declared in a extern "C"
block).
2010-05-31 12:29:54 -03:00
Tor Didriksen
a612981422 Bug #49829 Many "hides virtual function" warnings with SunStudio
Backport from mysql-pe (of those parts which have not been upmerged from 5.1)
2010-05-31 12:59:58 +02:00
Alexander Nozdrin
4e633ec234 Auto-merge from mysql-trunk. 2010-05-28 09:47:58 +04:00
Tor Didriksen
d8536dfbdd Bug #53445 Build with -Wall and fix warnings that it generates
Add -Wall to gcc/g++
Fix most warnings reported in dbg and opt mode.
2010-05-26 16:12:23 +02:00
Mattias Jonsson
e596ae0795 merge 2010-05-25 17:26:48 +02:00
Alexey Kopytov
ad43230e3b Manual merge of mysql-5.1-bugteam to mysql-trunk-merge.
Conflicts:

Text conflict in mysql-test/r/grant.result
Text conflict in mysql-test/t/grant.test
Text conflict in mysys/mf_loadpath.c
Text conflict in sql/slave.cc
Text conflict in sql/sql_priv.h
2010-05-09 02:03:35 +04:00
Georgi Kodinov
0f26a0533b Bug #53371: COM_FIELD_LIST can be abused to bypass table level grants.
This is the 5.1 merge and extension of the fix.
The server was happily accepting paths in table name in all places a table
name is accepted (e.g. a SELECT). This allowed all users that have some 
privilege over some database to read all tables in all databases in all
mysql server instances that the server file system has access to.
Fixed by :
1. making sure no path elements are allowed in quoted table name when
constructing the path (note that the path symbols are still valid in table names
when they're properly escaped by the server).
2. checking the #mysql50# prefixed names the same way they're checked for
path elements in mysql-5.0.
2010-05-04 17:03:28 +03:00
Mats Kindahl
e409d6f69c WL#5030: Split and remove mysql_priv.h
This patch:

- Moves all definitions from the mysql_priv.h file into
  header files for the component where the variable is
  defined
- Creates header files if the component lacks one
- Eliminates all include directives from mysql_priv.h
- Eliminates all circular include cycles
- Rename time.cc to sql_time.cc
- Rename mysql_priv.h to sql_priv.h
2010-03-31 16:05:33 +02:00
Mattias Jonsson
90c200a216 Bug#42954: SQL MODE 'NO_DIR_IN_CREATE' does not work with subpartitions
There was no check for DATA/INDEX DIRECTORY for subpartitions

Added the same check as for partitions.
2010-03-11 14:00:36 +01:00
Mikael Ronstrom
29c60cd5b7 BUG#49591, Fixed version string in SHOW CREATE TABLE to accomodate for column list partitioning and new function to_seconds 2009-12-17 18:39:10 +01:00
Mikael Ronstrom
de95fa0a7d BUG#49180, fixed MAXVALUE problem 2009-12-02 08:14:22 +01:00
Alexander Nozdrin
e81cd9dfe1 Fix build failure. 2009-11-10 12:32:29 +03:00
Mikael Ronstrom
c897c59ceb Fixed so that character set constants are encoded as hex strings in frm file, but as utf8 strings in the same manner as default values in show create table and information schema tables 2009-10-30 21:08:34 +01:00
Mikael Ronstrom
d9e05040f4 Merged WL#3352 into mysql-next-mr 2009-10-28 18:22:36 +01:00
Mikael Ronstrom
b572e51c30 BUG#48165, needed to introduce length restrictions on partitioning fields to ensure that no stack overruns occur 2009-10-28 01:11:17 +01:00
Mikael Ronstrom
59cc518990 Fixed sql_mode issue in BUG#48164, will ignore sql_mode when generating constants, also warnings will not be tolerated 2009-10-28 00:06:11 +01:00
Mikael Ronstrom
66f056a64c A lot of fixes to make character set work ok, first step to fixing BUG#48163 2009-10-22 16:15:06 +02:00
Mikael Ronstrom
57d455460d Added checks for no NULL values in VALUES LESS THAN, added tests for no MAXVALUE in VALUES IN 2009-10-21 20:53:44 +02:00
Mikael Ronstrom
3c8c881601 Fixed test cases with regards to error codes 2009-10-21 18:27:34 +02:00
Mikael Ronstrom
e541ab3b53 Removed unnecessary call to fix_parser_data 2009-10-21 17:28:10 +02:00
Mikael Ronstrom
8ac7705722 Removed column_list and fixed all issues relating to this change 2009-10-21 12:40:21 +02:00
Mikael Ronstrom
f42cc4a67f Merged in latest wl3352 tree, fixed some non-partition build issues 2009-10-19 13:06:21 +02:00
Mikael Ronstrom
8cf025ec3f Fix for non-partition builds 2009-10-19 09:10:25 +02:00
Mikael Ronstrom
1f38322dc4 Merged in latest changes 2009-10-16 17:44:49 +02:00
Mikael Ronstrom
05d7593fe3 Fixed review comments 2009-10-16 17:08:34 +02:00
Mikael Ronstrom
1ef62bf621 Fixed removal of column_list keyword for VALUES part, retained for PARTITION BY RANGE/LIST COLUMN_LIST, not entirely working yet 2009-10-16 16:16:06 +02:00
Mikael Ronstrom
b216aab1c4 BUG#47837, Duplicate field names were allowed in both column list partitioning and key partitioning, added check to give error in this case 2009-10-06 17:01:59 +02:00
Mikael Ronstrom
f9b0e5db3f BUG#47752, missed to sort values in list partitioning 2009-10-01 15:09:20 +02:00
Mikael Ronstrom
1fe164a20e Changed all no_ to num_ to avoid strange names like no_list_values which is not expected to be number of list values, rather a boolea indicating no list values 2009-10-01 15:04:42 +02:00
Staale Smedseng
8b9843408d Bug #43414 Parenthesis (and other) warnings compiling MySQL
with gcc 4.3.2

Cleaning up warnings not present in 5.0.
2009-09-23 15:21:29 +02:00
Mikael Ronstrom
12627d4072 WL#3352, Introducing Column list partitioning, makes it possible to partition on most data types, makes it possible to prune on multi-field partitioning 2009-09-15 17:07:52 +02:00
Mattias Jonsson
8f39d2584b Bug#40389: REORGANIZE PARTITION crashes when only using one partition
The non documented command 'ALTER PARTITION t REORGANIZE PARTITION'
(without any partitions!) which only make sense for nativly
partitioned engines, such as NDB, crashes the server if there was
no change of number of partitions.

The problem was wrong usage of fast_end_partition function,
which led to usage of a non initialized variable.
2008-12-02 11:18:01 +01:00
Marc Alff
d4d76a6a80 coding style 2008-10-07 16:14:58 -06:00
Marc Alff
e76bb8c665 Bug#36768 (partition_info::check_partition_info() reports mal formed
warnings)

Before this fix, several places in the code would raise a warning with an
error code 0, making it impossible for a stored procedure, a connector,
or a client application to trigger logic to handle the warning.
Also, the warning text was hard coded, and therefore not translated.

With this fix, new errors numbers have been created to represent these
warnings, and the warning text is coded in the errmsg.txt file.
2008-10-06 14:36:15 -06:00
mattiasj@witty.
d733351148 Bug#35305: partition_symlink test failures
Updated the test due to bug 32167

Corrected spelling of error message
2008-03-17 16:11:26 +01:00
antony@pcg5ppc.xiphis.org
91e44529bd Merge pcg5ppc.xiphis.org:/Network/Servers/anubis.xiphis.org/home/antony/work/mysql-5.1
into  pcg5ppc.xiphis.org:/Network/Servers/anubis.xiphis.org/home/antony/work/merge.20080307/mysql-5.1
2008-03-14 11:13:54 -07:00
gluh@mysql.com/eagle.(none)
9d42a09675 Bug#32167 another privilege bypass with DATA/INDEX DIRECORY(3rd version for 5.1)
added new function test_if_data_home_dir() which checks that
path does not contain mysql data home directory.
Using of 'mysql data home'/'any db name' in
DATA DIRECTORY & INDEX DIRECTORY is disallowed
2008-02-28 16:46:52 +04:00
mattiasj@witty.
2e3ed6a216 Post push fix
Fixed a missed case in the patch for Bug#31931.
Also makes Bug#33722 a duplicate of Bug#31931.
Added tests for better coverage.
Replaced some legacy function calls.
2008-02-25 21:18:50 +01:00
mattiasj@witty.
d3937fd63c Merge witty.:/Users/mattiasj/clones/mysql-5.1-bug31931.2
into  witty.:/Users/mattiasj/clones/topush-51
2008-02-24 16:46:35 +01:00
mattiasj@client-10-129-10-137.upp.off.mysql.com
a6a9774849 Bug#31931 Partitions: unjustified 'mix of handlers' error message
Problem was that the mix of handlers was not consistent between
CREATE and ALTER

changed so that it works like:
    - All partitions must use the same engine
      AND it must be the same as the table.
    - if one does NOT specify an engine on the table level
      then one must either NOT specify any engine on any
      partition/subpartition OR for ALL partitions/subpartitions

Note: that after a table have been created, the storage engine
is specified for all parts of the table (table/partition/subpartition)
and so when using alter, one does not need to specify it (unless one
wants to change the storage engine, then one have to specify it on the
table level)
2008-01-09 13:15:50 +01:00
mattiasj@witty.
5d6a65bb50 Bug#30459 Partitioning across disks failing on Windows
Problem was that there are no support for symlinked files on Windows for
mysqld. So we fail when trying to create them.

Solution: Ignore the DATA/INDEX DIRECTORY clause for partitions and push
a warning. (Just like a MyISAM table)
2008-01-04 12:06:20 +01:00
istruewing@stella.local
03d99c5956 Merge stella.local:/home2/mydev/mysql-5.1-amain
into  stella.local:/home2/mydev/mysql-5.1-axmrg
2007-12-11 21:37:33 +01:00