Skip to content

Commit

Permalink
fix: check bvlist nil check for delete op
Browse files Browse the repository at this point in the history
Signed-off-by: Harshit Gangal <[email protected]>
  • Loading branch information
harshit-gangal committed May 20, 2024
1 parent 8d6e593 commit f863651
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion go/vt/vtgate/engine/dml_with_input.go
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ func (dml *DMLWithInput) TryExecute(ctx context.Context, vcursor VCursor, bindVa
var res *sqltypes.Result
for idx, prim := range dml.DMLs {
var qr *sqltypes.Result
if len(dml.BVList[idx]) == 0 {
if len(dml.BVList) == 0 || len(dml.BVList[idx]) == 0 {
qr, err = executeLiteralUpdate(ctx, vcursor, bindVars, prim, inputRes, dml.OutputCols[idx])
} else {
qr, err = executeNonLiteralUpdate(ctx, vcursor, bindVars, prim, inputRes, dml.OutputCols[idx], dml.BVList[idx])
Expand Down

0 comments on commit f863651

Please sign in to comment.