dialect/sql/sqlgraph: catch SQLite INSERT errors executed with Driver.Query (#3415)

This commit is contained in:
Ariel Mashraki
2023-03-27 22:21:47 +03:00
committed by GitHub
parent b435c97c99
commit d9e7adfa05
2 changed files with 6 additions and 1 deletions

View File

@@ -1630,7 +1630,7 @@ func (c *batchCreator) insertLastIDs(ctx context.Context, tx dialect.ExecQuerier
return err
}
}
return nil
return rows.Err()
}
// MySQL.
var res sql.Result