Clone Tools
  • last updated 14 mins ago
Constraints
Constraints: committers
 
Constraints: files
Constraints: dates
[ASTERIXDB-2429] Fix the upsert of primary key index

- user model changes: no

- storage format changes: no

- interface changes: no

Details:

- Previously the primary key index is not properly maintained during

upsert. Since there is no secondary key in the primary key index, the

old value would always point to the primary key, which is always equal

to the new value. As a result, the primary key index is nevered

maintainined during upsert.

- This patch fixes this bug with two changes:

First, if there is a primary key index, we would perform upsert anyway

no matter whether old value == new value

Second, use a boolean variable to indicate whether the operation

is upsert or delete since for the primary key index, old value cannot

provide such information.

Change-Id: I925bd42ba67f70e94f5f5bc2d24151c8e2e20baf

Reviewed-on: https://asterix-gerrit.ics.uci.edu/2825

Sonar-Qube: Jenkins <jenkins@fulliautomatix.ics.uci.edu>

Tested-by: Jenkins <jenkins@fulliautomatix.ics.uci.edu>

Integration-Tests: Jenkins <jenkins@fulliautomatix.ics.uci.edu>

Contrib: Jenkins <jenkins@fulliautomatix.ics.uci.edu>

Reviewed-by: abdullah alamoudi <bamousaa@gmail.com>

    • -0
    • +28
    ./primary-secondary-btree.4.query.sqlpp
  1. … 21 more files in changeset.