title: How to update multiple model objects at a time with bulk_update?
body: <p>Here from the frontend user gives the input values like this ['1','2', '3']. I want to update the multiple objects at time with <code>bulk_update</code> and I tried like this but this is giving me this error.</p>
  <p><code>ValueError: All bulk_update() objects must have a primary key set.</code></p>
  <p>With this similar way I created objects with <code>bulk_create</code> method which worked fine but with <code>bulk_update</code> it is not workin.</p>
  <p><strong>Here I want to update multiple model objects with different values at a time ?</strong></p>
  <pre><code>class PVariant(models.Model):
      name = models.CharField(max_length=255)
      product = models.ForeignKey(Product, on_delete=models.CASCADE)
      ....
  
  #views
  
  quantity = request.POST.getlist('quantity')
  #['1','2','3']
  names = request.POST.getlist('names')
  fields = ['name', 'price', 'quantity'..]
  params = zip(names, quantity, weight,..)
  variants = [PVariant(name=param[0],sku=param[1], quantity=param[2], weight=param[3],
                                         product=product) for param in params]
  PVariant.objects.bulk_update(variants, fields)
            
  </code></pre>
  <p><strong>EDIT:</strong>
  From the client side I am getting this types of data in the view.</p>
  <pre><code>['name1', 'name2'] names
  ['12', '1213.0'] field1
  ['12.0', '12.0']  field2
  ['1244', '1244']  field3
  ['11', '11']   field4
  ['12.0', '12.0'] field5
  </code></pre>