Find your content:

Search form

You are here

Field is not setting to NULL value via DataStage

 
Share

There is an interface between Salesforce and DataStage for User object and Users are updated in Salesforce via DataStage job. There is a text field "District" on User object which has no special attributes, just a normal text field. DataStage is trying to update a particular User's District from some value 'ABC' district to NULL value. However, the field "District" still shows the same value "ABC" and not blank/null value. The success file from DataStage does say that it updated the item successfully, however when it enters Salesforce zone, the field is not updated on the user record.

Please advise what can be the issue and how we can resolve this to set the field to null value.


Attribution to: Vimal Desai

Possible Suggestion/Solution #1

EDIT : Additionally, it is worth checking for any before Triggers / workflows which could be resetting the District to the incumbent value. Also worth checking if setting it to null via the UI manually works.


What does the interface comprise of ? Is it DataLoader scheduled using Windows Task Scheduler, or a Cron ?

What is the value that the interface is inserting to the set the value to NULL?

If it is the DataLoader, then check your settings to see if the field "Insert Null Values" is checked.

To insert null values using bulk api instead of leaving that cell empty in the csv file you need to populate"#N/A" in that.

Reference : http://www.interactiveties.com/b_bulk_api_nulls.php


Attribution to: techtrekker

Possible Suggestion/Solution #2

vimal are you sure there are no triggers/formulas updating the field?

I would try to 1) See in the dev console if there are any workflows/formulas/triggers updating 2) Brute method : try to delete the field in a sandbox and it won't let u delete in case the trigger/workflow is updating the field.

Than that I would be curious to know why a null value would not be updated!!! Hope this helps!!!


Attribution to: Rao

Possible Suggestion/Solution #3

I'm not familiar with DataStage, but when updating records through the API, you need to explicitly set fields to null using the fieldsToNull property. In my experience with other integration tools, just setting a null on the field won't work.


Attribution to: Daniel Hoechst
This content is remixed from stackoverflow or stackexchange. Please visit https://salesforce.stackexchange.com/questions/3636

My Block Status

My Block Content