Commit graph

35136 commits

Author SHA1 Message Date
evgen@moonbone.local
111dc92786 Merge epotemkin@bk-internal.mysql.com:/home/bk/mysql-4.1-opt
into moonbone.local:/home/evgen/bk-trees/mysql-4.1-opt
2006-06-13 22:53:30 +04:00
mikael@c-0409e253.1238-1-64736c10.cust.bredbandsbolaget.se
59c0034061 BUG#19307: CSV engine can cause crashes in partitioned tables (due to its conversion of NULLs to 0) 2006-06-13 14:36:23 -04:00
mikael@c-0409e253.1238-1-64736c10.cust.bredbandsbolaget.se
d2b04770ac Merge c-0409e253.1238-1-64736c10.cust.bredbandsbolaget.se:/home/pappa/clean-mysql-5.1
into  c-0409e253.1238-1-64736c10.cust.bredbandsbolaget.se:/home/pappa/bug19305
2006-06-13 11:44:43 -04:00
mikael@c-0409e253.1238-1-64736c10.cust.bredbandsbolaget.se
c2f0bd70b5 fixed test case 2006-06-13 11:32:07 -04:00
gkodinov@mysql.com
8d94b8cacf Bug #20195: INSERT DELAYED with auto_increment is assigned wrong values
The INSERT DELAYED should not maintain its own private auto-increment
counter, because this is assuming that other threads cannot insert
into the table while the INSERT DELAYED thread is inserting, which is
a wrong assumption.

So the start of processing of a batch of INSERT rows in the 
INSERT DELAYED thread must be treated as a start of a new statement
and cached next_insert_id must be cleared.
2006-06-13 18:18:32 +03:00
evgen@moonbone.local
d4942a2635 Merge epotemkin@bk-internal.mysql.com:/home/bk/mysql-4.1-opt
into moonbone.local:/work/16377-bug-4.1-opt-mysql
2006-06-13 19:10:27 +04:00
evgen@moonbone.local
67de8c46a5 Fixed bug#16377: result of DATE/TIME functions were compared as strings which
can lead to a wrong result.

All date/time functions has the STRING result type thus their results are
compared as strings. The string date representation allows a user to skip 
some of leading zeros. This can lead to wrong comparison result if a date/time 
function result is compared to such a string constant.

The idea behind this bug fix is to compare results of date/time functions
and data/time constants as ints, because that date/time representation is 
more exact. To achieve this the agg_cmp_type() is changed to take in the
account that a date/time field or an date/time item should be compared 
as ints.

This bug fix is partially back ported from 5.0.

The agg_cmp_type() function now accepts THD as one of parameters. 
In addition, it now checks if a date/time field/function is present in the
list. If so, it tries to coerce all constants to INT to make date/time
comparison return correct result. The field for the constant coercion is
taken from the Item_field or constructed from the Item_func. In latter case
the constructed field will be freed after conversion of all constant items.
Otherwise the result is same as before - aggregated with help of the
item_cmp_type() function.

From the Item_func_between::fix_length_and_dec() function removed the part
which was converting date/time constants to int if possible. Now this is 
done by the agg_cmp_type() function.

The new function result_as_longlong() is added to the Item class. 
It indicates that the item is a date/time item and result of it can be
compared as int. Such items are date/time fields/functions.

Correct val_int() methods are implemented for classes Item_date_typecast, 
Item_func_makedate, Item_time_typecast, Item_datetime_typecast. All these
classes are derived from Item_str_func and Item_str_func::val_int() converts
its string value to int without regard to the date/time type of these items.

Arg_comparator::set_compare_func() and Arg_comparator::set_cmp_func()
functions are changed to substitute result type of an item with the INT_RESULT
if the item is a date/time item and another item is a constant. This is done
to get a correct result of comparisons like date_time_function() = string_constant.
2006-06-13 19:09:24 +04:00
mskold@mysql.com
95d61f64d8 Fixed incorrect handling of renamed fields, forcing copy of table if needed and added optional system variable ndb_use_copying_alter_table 2006-06-13 16:44:30 +02:00
mikael@c-0409e253.1238-1-64736c10.cust.bredbandsbolaget.se
192033c7a2 Merge c-0409e253.1238-1-64736c10.cust.bredbandsbolaget.se:/home/pappa/bug19122
into  c-0409e253.1238-1-64736c10.cust.bredbandsbolaget.se:/home/pappa/bug19305
2006-06-12 17:49:38 -04:00
mikael@c-0409e253.1238-1-64736c10.cust.bredbandsbolaget.se
44076b96a1 Merge c-0409e253.1238-1-64736c10.cust.bredbandsbolaget.se:/home/pappa/clean-mysql-5.1
into  c-0409e253.1238-1-64736c10.cust.bredbandsbolaget.se:/home/pappa/bug19122
2006-06-12 17:41:05 -04:00
mikael@c-0409e253.1238-1-64736c10.cust.bredbandsbolaget.se
92dec44ef9 BUG#19122: Need to close handlers before drop/rename phase
Fixed comments
2006-06-12 17:37:32 -04:00
mikael@c-0409e253.1238-1-64736c10.cust.bredbandsbolaget.se
30817b8900 BUG#19122: Need to close all handlers before rename/drop phase in ALTER TABLE ADD/DROP/REORGANIZE partitions
After review fix
2006-06-12 17:30:32 -04:00
pekka@orca.ndb.mysql.com
0685030416 Merge pnousiainen@bk-internal.mysql.com:/home/bk/mysql-5.1
into  clam.ndb.mysql.com:/space/pekka/ndb/version/my51
2006-06-12 22:09:48 +02:00
mikael@c-0409e253.1238-1-64736c10.cust.bredbandsbolaget.se
334a28f9f5 Merge c-0409e253.1238-1-64736c10.cust.bredbandsbolaget.se:/home/pappa/bug19695
into  c-0409e253.1238-1-64736c10.cust.bredbandsbolaget.se:/home/pappa/bug19305
2006-06-12 14:50:46 -04:00
mikael@c-0409e253.1238-1-64736c10.cust.bredbandsbolaget.se
744bb5d7bb Merge c-0409e253.1238-1-64736c10.cust.bredbandsbolaget.se:/home/pappa/clean-mysql-5.1
into  c-0409e253.1238-1-64736c10.cust.bredbandsbolaget.se:/home/pappa/bug19695
2006-06-12 14:42:07 -04:00
mikael@c-0409e253.1238-1-64736c10.cust.bredbandsbolaget.se
9aa3af6723 Merge c-0409e253.1238-1-64736c10.cust.bredbandsbolaget.se:/home/pappa/clean-mysql-5.1
into  c-0409e253.1238-1-64736c10.cust.bredbandsbolaget.se:/home/pappa/bug19305
2006-06-12 14:31:25 -04:00
pekka@clam.ndb.mysql.com
800e1e56a9 ndb - bug#19872 fix (sufficient for replication) 2006-06-12 18:00:06 +02:00
gkodinov@mysql.com
df358201e8 Merge mysql.com:/home/kgeorge/mysql/5.0/clean
into  mysql.com:/home/kgeorge/mysql/5.0/B20363
2006-06-12 18:28:04 +03:00
gkodinov@mysql.com
eb693dcc7b Bug #20363: Create view on just created view is now denied
There was a wrong determination of the DB name (witch is 
not always the one in TABLE_LIST because derived tables
may be calculated using temp tables that have their db name
set to "").
The fix determines the database name according to the type 
of table reference, and calls the function check_access() 
with the correct db name so the correct set of grants is found.
2006-06-12 18:15:08 +03:00
acurtis@xiphis.org
32fbbbb9b6 Merge acurtis@bk-internal.mysql.com:/home/bk/mysql-5.1-engines
into  xiphis.org:/home/antony/work2/p2-bug20168.2
2006-06-12 06:53:31 -07:00
acurtis@xiphis.org
62729fcdfe Bug#20168
"Change in behavior --default-storage-engine=ndb or ndbcluster"
  Reduce use of legacy_db_type, some code cleanup
  (serg read my mind and implemented desired mysqld.cc changes)
2006-06-12 06:50:11 -07:00
mskold@mysql.com
69d52db924 Added order by 2006-06-12 15:36:12 +02:00
mskold@mysql.com
4242beb31d Merge mskold@bk-internal.mysql.com:/home/bk/mysql-5.0
into  mysql.com:/home/marty/MySQL/mysql-5.0
2006-06-12 15:36:10 +02:00
tomas@poseidon.ndb.mysql.com
a590e5dc82 Merge tulin@bk-internal.mysql.com:/home/bk/mysql-5.0
into  poseidon.ndb.mysql.com:/home/tomas/mysql-5.0-main
2006-06-12 15:36:09 +02:00
mskold@mysql.com
47bb569979 Added order by 2006-06-12 15:35:47 +02:00
mskold@mysql.com
049c3e3f69 Merge mskold@bk-internal.mysql.com:/home/bk/mysql-4.1
into  mysql.com:/home/marty/MySQL/mysql-4.1
2006-06-12 15:35:46 +02:00
tomas@poseidon.ndb.mysql.com
9ec2be748c Merge tulin@bk-internal.mysql.com:/home/bk/mysql-4.1
into  poseidon.ndb.mysql.com:/home/tomas/mysql-4.1-main
2006-06-12 15:35:45 +02:00
mskold@mysql.com
ae70201afb Added order by 2006-06-12 15:28:36 +02:00
mskold@linux.site
40e6161fdd Merge mskold@bk-internal.mysql.com:/home/bk/mysql-5.1
into  mysql.com:/home/marty/MySQL/mysql-5.1
2006-06-12 14:36:06 +02:00
mskold@mysql.com
38a445fee1 sql_delete.cc:
Bug #18864  TRUNCATE TABLE doesn't reset AUTO_INCREMENT value on ndb table: locked lock_OPEN mutex to support TRUNCATE with re-create and cluster binlog
Many files:
  Bug #18864  TRUNCATE TABLE doesn't reset AUTO_INCREMENT value on ndb table: adaption to MySQ Cluster replication
ndb_lock.result, ha_ndbcluster.cc:
  Fix for Bug #18184  SELECT ... FOR UPDATE does not work..: Adaption to 5.1 code
NdbDictionaryImpl.hpp:
  Fix of bad merge
2006-06-12 14:23:21 +02:00
evgen@moonbone.local
147961bc59 Merge epotemkin@bk-internal.mysql.com:/home/bk/mysql-4.1-opt
into moonbone.local:/home/evgen/bk-trees/mysql-4.1-opt
2006-06-12 15:56:21 +04:00
evgen@moonbone.local
e831704a33 Merge moonbone.local:/work/16716-bug-4.1-mysql
into moonbone.local:/work/16716-bug-4.1-opt-mysql
2006-06-12 15:50:59 +04:00
tomas@poseidon.ndb.mysql.com
faa2f09107 Merge jonas@perch:src/51-jonas
into  poseidon.ndb.mysql.com:/home/tomas/mysql-5.1-new-ndb
2006-06-12 13:46:10 +02:00
tomas@poseidon.ndb.mysql.com
cd90b5d777 Merge tulin@bk-internal.mysql.com:/home/bk/mysql-5.1
into  poseidon.ndb.mysql.com:/home/tomas/mysql-5.1-new-ndb
2006-06-12 13:29:33 +02:00
tomas@poseidon.ndb.mysql.com
cb3a75a4ee Merge poseidon.ndb.mysql.com:/home/tomas/mysql-5.0
into  poseidon.ndb.mysql.com:/home/tomas/mysql-5.1-new-ndb
2006-06-12 13:12:03 +02:00
tomas@poseidon.ndb.mysql.com
8d8081ff3d Merge poseidon.ndb.mysql.com:/home/tomas/mysql-5.0
into  poseidon.ndb.mysql.com:/home/tomas/mysql-5.0-main
2006-06-12 13:11:37 +02:00
tomas@poseidon.ndb.mysql.com
3996410cfa Merge poseidon.ndb.mysql.com:/home/tomas/mysql-4.1
into  poseidon.ndb.mysql.com:/home/tomas/mysql-4.1-main
2006-06-12 13:09:04 +02:00
tomas@poseidon.ndb.mysql.com
ccd0b3e3ca Merge poseidon.ndb.mysql.com:/home/tomas/mysql-4.1
into  poseidon.ndb.mysql.com:/home/tomas/mysql-5.0
2006-06-12 13:08:04 +02:00
tomas@poseidon.ndb.mysql.com
697db8f043 Bug #20336 CLUSTERLOG commands have no effect
- always calculate max log level on node start
- send event subscribe uncond
2006-06-12 13:06:56 +02:00
mskold@mysql.com
be60898441 Merge mysql.com:/home/marty/MySQL/mysql-5.0
into  mysql.com:/home/marty/MySQL/mysql-5.1
2006-06-12 11:34:00 +02:00
mskold@mysql.com
d17c3d3c7c Fix for Bug #18184 SELECT ... FOR UPDATE does not work..: Skipped lock check for full table scan due to bug #20390 SELECT FOR UPDATE does not release locks of untouched rows in full table scans 2006-06-12 10:40:56 +02:00
mskold@mysql.com
58f686f985 Fix for Bug #18184 SELECT ... FOR UPDATE does not work..: Added missing parameter for readTuples in index scan 2006-06-12 10:22:32 +02:00
mskold@mysql.com
b93ba41e68 Merge mysql.com:/home/marty/MySQL/mysql-4.1
into  mysql.com:/home/marty/MySQL/mysql-5.0
2006-06-12 09:42:20 +02:00
mskold@mysql.com
e7c1a57f3d Fix for Bug #18184 SELECT ... FOR UPDATE does not work..: Adapted to 5.0 code changes 2006-06-12 09:37:19 +02:00
mskold@mysql.com
b89f17912c Added lock test on index scan 2006-06-12 09:28:27 +02:00
mskold@mysql.com
030f63fdab Moved back comment to correct method 2006-06-12 09:27:04 +02:00
igor@rurik.mysql.com
bb94b35f2f Merge ibabaev@bk-internal.mysql.com:/home/bk/mysql-5.0-opt
into  rurik.mysql.com:/home/igor/mysql-5.0-opt
2006-06-11 13:45:18 -07:00
ingo@mysql.com
76f066aa32 Merge mysql.com:/home/mydev/mysql-5.0
into  mysql.com:/home/mydev/mysql-5.0-amerge
2006-06-10 12:24:44 +02:00
ingo@chilla.local
a94ad6a2e3 Merge mysql.com:/home/mydev/mysql-5.1--main
into  mysql.com:/home/mydev/mysql-5.1-amerge
2006-06-10 06:15:26 +02:00
igor@rurik.mysql.com
60620b31fe Post-merge fixes 2006-06-09 19:29:39 -07:00