mirror of
https://github.com/aljazceru/turso.git
synced 2026-02-09 18:24:20 +01:00
add some comments
This commit is contained in:
@@ -1067,6 +1067,9 @@ fn emit_update_insns(
|
||||
});
|
||||
}
|
||||
|
||||
// If we are updating the rowid, we cannot rely on overwrite on the
|
||||
// Insert instruction to update the cell. We need to first delete the current cell
|
||||
// and later insert the updated record
|
||||
if has_user_provided_rowid {
|
||||
program.emit_insn(Insn::Delete { cursor_id });
|
||||
}
|
||||
|
||||
@@ -293,6 +293,7 @@ pub fn prepare_update_plan(
|
||||
.joined_tables()
|
||||
.first()
|
||||
.unwrap();
|
||||
// We do not need to emit an ephemeral plan if we are not going to loop over the table values
|
||||
if matches!(table.op, Operation::Search(Search::RowidEq { .. })) {
|
||||
(None, vec![])
|
||||
} else {
|
||||
|
||||
Reference in New Issue
Block a user