Issue Details (XML | Word | Printable)

Key: CORE-6089
Type: Bug Bug
Status: Closed Closed
Resolution: Fixed
Priority: Major Major
Assignee: Vlad Khorsun
Reporter: Dmitry Yemanov
Votes: 0
Watchers: 2
Operations

If you were logged in you would be able to see more operations.
Firebird Core

BLOBs are unnecessarily copied during UPDATE after a table format change

Created: 29/Jun/19 08:00 AM   Updated: 06/Jul/19 09:07 AM
Component/s: Engine
Affects Version/s: 3.0.3, 3.0.4, 4.0 Beta 1
Fix Version/s: 3.0.5, 4.0 Beta 2

Issue Links:
Relate

QA Status: Done successfully


 Description  « Hide
Test case:

recreate table t (col1 int, col2 blob);

insert into t values (1, '1');
insert into t values (2, '2');
insert into t values (3, '3');
commit;

select * from t;

        COL1 COL2
============ =================
           1 84:0
           2 84:1
           3 84:2

update t set col1 = -col1;
select * from t;

        COL1 COL2
============ =================
          -1 84:0
          -2 84:1
          -3 84:2

-- So far so good: COL1 is negated, COL2 has the same BLOB IDs

rollback;

alter table t add col3 date;

select * from t;

        COL1 COL2 COL3
============ ================= ===========
           1 84:0 <null>
           2 84:1 <null>
           3 84:2 <null>

update t set col1 = -col1;
select * from t;

        COL1 COL2 COL3
============ ================= ===========
          -1 84:3 <null>
          -2 84:4 <null>
          -3 84:5 <null>

-- BUG: COL2 has different BLOB IDs, i.e. the whole blobs were copied rather than just their IDs

rollback;

This is a regression introduced while fixing CORE-5600. v3.0.3 and later versions are affected.

 All   Comments   Change History   Subversion Commits      Sort Order: Ascending order - Click to sort in descending order
There are no comments yet on this issue.