You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
With an indexed list we have an index column. Consequently whenever adding / removing from an indexed list at a position we need to shift all existing elements AFTER that position down to create space.
If we have a list of 10 elements using an index, and we do a List.remove(3) then we get
UPDATE B SET A_ID_OID=NULL, ORDERIDX=-1 WHERE A_ID_OID=1 AND ORDERIDX=3
UPDATE B SET ORDERIDX = ORDERIDX + -1 WHERE A_ID_OID=1 AND ORDERIDX=4
UPDATE B SET ORDERIDX = ORDERIDX + -1 WHERE A_ID_OID=1 AND ORDERIDX=5
UPDATE B SET ORDERIDX = ORDERIDX + -1 WHERE A_ID_OID=1 AND ORDERIDX=6
UPDATE B SET ORDERIDX = ORDERIDX + -1 WHERE A_ID_OID=1 AND ORDERIDX=7
UPDATE B SET ORDERIDX = ORDERIDX + -1 WHERE A_ID_OID=1 AND ORDERIDX=8
UPDATE B SET ORDERIDX = ORDERIDX + -1 WHERE A_ID_OID=1 AND ORDERIDX=9
whereas we ought to do
UPDATE B SET A_ID_OID=NULL, ORDERIDX=-1 WHERE A_ID_OID=1 AND ORDERIDX=3
UPDATE B SET ORDERIDX = ORDERIDX + -1 WHERE A_ID_OID=1 AND ORDERIDX>3
The text was updated successfully, but these errors were encountered:
Backport from #413 on master branch.
With an indexed list we have an index column. Consequently whenever adding / removing from an indexed list at a position we need to shift all existing elements AFTER that position down to create space.
If we have a list of 10 elements using an index, and we do a List.remove(3) then we get
whereas we ought to do
The text was updated successfully, but these errors were encountered: