Commit graph

36056 commits

Author SHA1 Message Date
dlenev@mysql.com
eb3ae6eb79 Merge mysql.com:/home/dlenev/mysql-5.0-bg18437-3
into  mysql.com:/home/dlenev/mysql-5.1-bg18437
2006-07-02 02:12:53 +04:00
dlenev@mysql.com
d4450e6696 Fix for bug#18437 "Wrong values inserted with a before update trigger on
NDB table".

SQL-layer was not marking fields which were used in triggers as such. As
result these fields were not always properly retrieved/stored by handler
layer. So one might got wrong values or lost changes in triggers for NDB,
Federated and possibly InnoDB tables.
This fix solves the problem by marking fields used in triggers
appropriately.

Also this patch contains the following cleanup of ha_ndbcluster code:

We no longer rely on reading LEX::sql_command value in handler in order
to determine if we can enable optimization which allows us to handle REPLACE
statement in more efficient way by doing replaces directly in write_row()
method without reporting error to SQL-layer.
Instead we rely on SQL-layer informing us whether this optimization
applicable by calling handler::extra() method with
HA_EXTRA_WRITE_CAN_REPLACE flag.
As result we no longer apply this optimzation in cases when it should not
be used (e.g. if we have on delete triggers on table) and use in some
additional cases when it is applicable (e.g. for LOAD DATA REPLACE).

Finally this patch includes fix for bug#20728 "REPLACE does not work
correctly for NDB table with PK and unique index".
  
This was yet another problem which was caused by improper field mark-up.
During row replacement fields which weren't explicity used in REPLACE
statement were not marked as fields to be saved (updated) so they have
retained values from old row version. The fix is to mark all table
fields as set for REPLACE statement. Note that in 5.1 we already solve
this problem by notifying handler that it should save values from all
fields only in case when real replacement happens.
2006-07-02 01:51:10 +04:00
konstantin@mysql.com
1c4dffc8ca Merge bk-internal.mysql.com:/home/bk/mysql-5.0
into  mysql.com:/opt/local/work/mysql-5.0-runtime
2006-07-01 22:13:42 +04:00
sergefp@mysql.com
775ec4fb85 Post-merge fix 2006-07-01 09:28:41 +04:00
mikael@dator5.(none)
55109a802d Merge dator5.(none):/home/pappa/bug20583
into  dator5.(none):/home/pappa/bug17138
2006-07-01 00:28:04 -04:00
mikael@dator5.(none)
9e56572e5c Merge dator5.(none):/home/pappa/clean-mysql-5.1
into  dator5.(none):/home/pappa/bug20583
2006-07-01 00:22:25 -04:00
mikael@dator5.(none)
5853823bb2 Merge dator5.(none):/home/pappa/clean-mysql-5.1
into  dator5.(none):/home/pappa/bug17138
2006-07-01 00:19:23 -04:00
mikael@dator5.(none)
4e390d711a BUG#17138: Crashes in stored procedure
Last round of review fixes
2006-07-01 00:01:37 -04:00
sergefp@mysql.com
f863685241 Merge spetrunia@bk-internal.mysql.com:/home/bk/mysql-5.0
into  mysql.com:/home/psergey/mysql-5.0-bug16168-merge
2006-07-01 07:04:27 +04:00
evgen@moonbone.local
a3deb94518 Merge epotemkin@bk-internal.mysql.com:/home/bk/mysql-5.1
into moonbone.local:/work/merge-5.1
2006-07-01 05:59:26 +04:00
evgen@moonbone.local
1459784aba Reverted wrong bug fix (Bug#11228) 2006-07-01 01:37:20 +04:00
sergefp@mysql.com
784b3118a5 Merge mysql.com:/home/psergey/mysql-4.1-bug16168-push
into  mysql.com:/home/psergey/mysql-5.0-bug16168-merge
2006-07-01 01:25:59 +04:00
konstantin@mysql.com
fbeb42a9e1 Remove an unused variable. 2006-07-01 00:33:47 +04:00
konstantin@mysql.com
41fea3d763 Remove a couple of unused/barely used names. 2006-07-01 00:14:28 +04:00
monty@mysql.com
f62829636b After merge fixes 2006-06-30 20:07:33 +03:00
knielsen@devsrv-b.mysql.com
79ebe92208 Merge bk-internal:/home/bk/mysql-5.1
into  mysql.com:/data0/knielsen/tmp-5.1
2006-06-30 18:20:45 +02:00
monty@mysql.com
2f86009c9e Merge mysql.com:/home/my/mysql-4.1
into  mysql.com:/home/my/mysql-5.0
2006-06-30 19:15:18 +03:00
monty@mysql.com
445dfdc3a7 Merge bk-internal.mysql.com:/home/bk/mysql-4.1
into  mysql.com:/home/my/mysql-4.1
2006-06-30 19:15:17 +03:00
tomas@poseidon.ndb.mysql.com
805551ead3 Merge tulin@bk-internal.mysql.com:/home/bk/mysql-4.1
into  poseidon.ndb.mysql.com:/home/tomas/mysql-4.1-main
2006-06-30 18:15:16 +02:00
monty@mysql.com
2bec1b86bb Reverted wrong bug fix (Bug#11228) 2006-06-30 18:29:27 +03:00
tomas@poseidon.ndb.mysql.com
c8b65bb357 manual merge, patch only relevant for 4.1 2006-06-30 16:29:17 +02:00
tomas@poseidon.ndb.mysql.com
e61bfafaa9 Merge poseidon.ndb.mysql.com:/home/tomas/mysql-4.1
into  poseidon.ndb.mysql.com:/home/tomas/mysql-4.1-main
2006-06-30 16:26:33 +02:00
tomas@poseidon.ndb.mysql.com
9f542ef0f4 adopted ndb handler code for tables without primary key and with unique index
- added missing retrieval of hidden primary key
2006-06-30 16:25:07 +02:00
kroki@mysql.com
96bddcafe7 Bug#17226: Variable set in cursor on first iteration is assigned
second iterations value

During assignment to the BLOB variable in routine body the value
wasn't copied.
2006-06-30 18:14:22 +04:00
knielsen@rt.int.sifira.dk
dcd9132fe7 Merge mysql.com:/usr/local/mysql/mysql-5.1-bindist
into  mysql.com:/usr/local/mysql/tmp-5.1
2006-06-30 15:21:45 +02:00
knielsen@mysql.com
5b1c92244c Add a script scripts/make_win_bin_dist, used to generate a Windows
binary disctribution for Falcon.
2006-06-30 15:15:20 +02:00
evgen@moonbone.local
a989f7261e Merge moonbone.local:/home/evgen/bk-trees/mysql-5.0-opt
into moonbone.local:/work/merge-5.1
2006-06-30 16:10:26 +04:00
evgen@moonbone.local
adbd5fb185 Manual merge 2006-06-30 16:09:14 +04:00
lars@mysql.com
78a9adb659 Changed the number of test iterations since this makes test time
go from 623 seconds to 11 seconds on AMD64.
This is because we have no native atomic implementation on AMD64, 
so the rwlock-based implementation is used, which is  a bit slow.  
It will be probably be optimized for AMD64 quite soon, but for now 
this test case will do fewer iterations.
2006-06-30 11:31:43 +02:00
jonas@perch.ndb.mysql.com
05f14b144b Merge perch.ndb.mysql.com:/home/jonas/src/51-work
into  perch.ndb.mysql.com:/home/jonas/src/mysql-5.1-new-ndb
2006-06-30 11:26:47 +02:00
jonas@perch.ndb.mysql.com
75c9f3cd01 Merge perch.ndb.mysql.com:/home/jonas/src/51-work
into  perch.ndb.mysql.com:/home/jonas/src/mysql-5.1-new
2006-06-30 11:26:10 +02:00
jonas@perch.ndb.mysql.com
2711af699c Merge joreland@bk-internal.mysql.com:/home/bk/mysql-5.1-new-ndb
into  perch.ndb.mysql.com:/home/jonas/src/mysql-5.1-new-ndb
2006-06-30 11:19:55 +02:00
jonas@perch.ndb.mysql.com
bc621b6418 Merge joreland@bk-internal.mysql.com:/home/bk/mysql-5.1
into  perch.ndb.mysql.com:/home/jonas/src/mysql-5.1-new
2006-06-30 11:18:31 +02:00
knielsen@mysql.com
a5f362cb94 Merge mysqldev@production:my/mysql-5.0-release
into  mysql.com:/usr/local/mysql/tmp-5.0
2006-06-30 11:11:49 +02:00
knielsen@mysql.com
a3019ab196 Fix Windows build problem following previous push. 2006-06-30 11:10:38 +02:00
kroki@mysql.com
69f0e87b05 Merge mysql.com:/home/tomash/src/mysql_ab/mysql-4.1
into  mysql.com:/home/tomash/src/mysql_ab/mysql-4.1-bug20152
2006-06-30 12:54:11 +04:00
kroki@mysql.com
79ca4c1d55 bug #20152: mysql_stmt_execute() overwrites parameter buffers
When using a parameter bind MYSQL_TYPE_DATE in a prepared statement,
the time part of the MYSQL_TIME buffer was written to zero in
mysql_stmt_execute(). The param_store_date() function in libmysql.c
worked directly on the provided buffer.
Changed to use a copy of the buffer.
2006-06-30 12:52:05 +04:00
jonas@perch.ndb.mysql.com
8e11f6f508 Merge perch.ndb.mysql.com:/home/jonas/src/50-work
into  perch.ndb.mysql.com:/home/jonas/src/51-work
2006-06-30 10:31:43 +02:00
jonas@perch.ndb.mysql.com
a4bfd31865 Merge perch.ndb.mysql.com:/home/jonas/src/41-work
into  perch.ndb.mysql.com:/home/jonas/src/50-work
2006-06-30 09:42:15 +02:00
jonas@perch.ndb.mysql.com
ab3992771b ndb - bug#20774
crash if system restart with more than 4096 fragments
  solution: continueb enable expand check loop
2006-06-30 09:41:41 +02:00
knielsen@mysql.com
af48a16ce3 Merge mysqldev@production.mysql.com:my/mysql-5.0-release
into  mysql.com:/usr/local/mysql/mysql-5.0-release
2006-06-30 09:28:06 +02:00
knielsen@mysql.com
1d56a9720c BUG#20769: Dangling pointer in ctype_recoding test case.
In some functions dealing with strings and character sets, the wrong
pointers were saved for restoration in THD::rollback_item_tree_changes().
This could potentially cause random corruption or crashes.

Fixed by passing the original Item ** locations, not local stack copies.

Also remove unnecessary use of default arguments.
2006-06-30 09:26:36 +02:00
petr@owlet.
b655968123 Merge pchardin@bk-internal.mysql.com:/home/bk/mysql-5.1
into  mysql.com:/home/cps/mysql/trees/5.1-team
2006-06-30 11:17:53 +04:00
sergefp@mysql.com
611e20d8e1 BUG#16168: Wrong results from range optimizer, "Use_count: Wrong count for key ..." warnings:
- Added comments.
 - Make SEL_ARG::clone() set SEL_ARG::elements in the created copy.
2006-06-30 09:05:12 +04:00
elliot@mysql.com
68db32613b Merge mysql.com:/home/emurphy/src/bk-clean/mysql-4.1
into  mysql.com:/home/emurphy/src/bk-clean/mysql-5.0
2006-06-30 00:14:25 -04:00
petr@mysql.com
c95ad6158a cleanup 2006-06-30 08:11:51 +04:00
elliot@mysql.com
5cd5e48761 Fixing windows build. 2006-06-30 00:10:41 -04:00
monty@mysql.com
2356a54ca1 Merge bk-internal.mysql.com:/home/bk/mysql-5.0
into  mysql.com:/home/my/mysql-5.0
2006-06-30 04:28:04 +03:00
monty@mysql.com
f25b4e0464 Merge bk-internal.mysql.com:/home/bk/mysql-4.1
into  mysql.com:/home/my/mysql-4.1
2006-06-30 04:27:19 +03:00
monty@mysql.com
c887b91d63 Merge monty@192.168.0.9:/home/my/mysql-4.1
into  mysql.com:/home/my/mysql-4.1
2006-06-30 04:26:41 +03:00