I'm trying to perform an update on our users using Python's Salesforce Bulk interface. Each account has a User ID field (UserID__c, External ID, Unique Case Insensitive) and a Parent ID field (ParentID__c, Lookup(Account)). I am trying to update the Parent ID field on the account using the Bulk API. A sample of the CSV looks like:


Based on the documentation, I expect that the Parent ID field of user 456 would be updated with the account belonging to the user with User ID 123, but the Parent ID field is always blank. There are no errors when I run the code, but the update for this field never happens. I am able to use the same code to update other field values. Is there something wrong with how I am referencing the lookup relationship?

1 Answer 1


I was able to resolve the issue by using an upsert request, rather than an update request, with the external ID field specified in the body. My code ended up looking something like this:

bulk = SalesforceBulk(sf['access_token'], sf['endpoint'])
job = bulk.create_upsert_job('Account', external_id_name='UserID__c')
  • This answer helped me figure out how to handle null values.
    – ctp_9
    Commented Oct 27, 2017 at 16:39

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .