Bug #20535 NDB API implicit insert of NULL does not overwrite old value
Submitted: 19 Jun 2006 13:07 Modified: 15 May 2007 6:16
Reporter: Pekka Nousiainen Email Updates:
Status: Closed Impact on me:
None 
Category:MySQL Cluster: NDB API Severity:S3 (Non-critical)
Version:5.1 OS:Linux (linux)
Assigned to: Jonas Oreland CPU Architecture:Any

[19 Jun 2006 13:07] Pekka Nousiainen
Description:
In a multi-op transaction, delete followed by insert
with implicit NULL value does not overwrite old 
(before delete) value.

Implicit: omit call to setValue(col, NULL).

This is NDB API specific since MySQL provides
even NULL values.

How to repeat:
In NDB API do:
   create table t1 (a int primary key, b int);
   insert into t1 values(1, 123);
   commit;
   delete from t1 where a = 1;
   insert into t1(a) values (1);
   commit;
   select * from t1 =>
   a   b
   1   123

Suggested fix:
TUP
[8 May 2007 13:00] Bugs System
A patch for this bug has been committed. After review, it may
be pushed to the relevant source trees for release in the next
version. You can access the patch from:

  http://lists.mysql.com/commits/26292

ChangeSet@1.2476, 2007-05-08 14:59:57+02:00, jonas@perch.ndb.mysql.com +3 -0
  ndb - bug#20535
    set null bits on delete+insert
[8 May 2007 14:11] Bugs System
A patch for this bug has been committed. After review, it may
be pushed to the relevant source trees for release in the next
version. You can access the patch from:

  http://lists.mysql.com/commits/26304

ChangeSet@1.2519, 2007-05-08 16:10:38+02:00, jonas@perch.ndb.mysql.com +2 -0
  ndb - bug#20535
    also handle dynamic attributes
[10 May 2007 12:57] Bugs System
Pushed into 5.1.19-beta
[15 May 2007 6:16] Jon Stephens
Thank you for your bug report. This issue has been committed to our source repository of that product and will be incorporated into the next release.

If necessary, you can access the source repository and build the latest available version, including the bug fix. More information about accessing the source trees is available at

    http://dev.mysql.com/doc/en/installing-source.html

Documented bugfix in 5.1.19 and telco-6.1.7 changelogs.