Incorrect result set (missing records) may be returned by the ORDER plan query navigating on a descending index [CORE5226] #5506
Labels
affect-version: 2.1.7
affect-version: 2.5.0
affect-version: 2.5.1
affect-version: 2.5.2 Update 1
affect-version: 2.5.2
affect-version: 2.5.3 Update 1
affect-version: 2.5.3
affect-version: 2.5.4
affect-version: 2.5.5
affect-version: 3.0.0
affect-version: 4.0 Initial
component: engine
fix-version: 2.5.6
fix-version: 3.0.1
fix-version: 4.0 Alpha 1
priority: major
qa: deferred
type: bug
Submitted by: Boltik Evgeny (bolt)
It happens only if the index key was removed (concurrently or by the cooperative GC) after reading it but before validating it using the fetched record. Only DESC indices are affected, the issue also depends on index key values. The bug seems to be inherited from InterBase.
Simplified example (leaf page layout):
key A, length 23, points to record 120006 (old version to be GCed)
key B, length 22, points to record 119054
key C, length 22, points to record 119535
key D, length 22, points to record 120006 (last committed version)
Key A gets GCed while reading and disappears, but key B is skipped and only records for C and D are returned. The second execution (with no GC involved) correctly returns {B, C, D}. The issue manifests itself only if key B has all its 22 bytes equal to key A (which is one byte longer).
Commits: e8bd26a 16e356f 3b7b316
====== Test Details ======
Waiting for suggest how to implement this test, letter to/from dimitr 06-may-2016 22:51.
The text was updated successfully, but these errors were encountered: