Here is my use case : When a customers clicks on a CTA "call me now" (in an email), he lands on a landing page (created using marketing cloud - cloud pages).

On this landing page, thanks to ampscript, the field "callback_detail__c" in the data extension Task_Salesforce takes the value "immediate_callback".

Here is the ampscript used in the email that contains the CTA "call me now":

    var @rows, @row, @rowCount, @numRowsToReturn, @i
    var @subkey, @WhoId, @callback_detail__c 
    var @link

    set @numRowsToReturn = 0 
    set @subkey = _subscriberkey
    set @rows = LookupOrderedRows("ENT.Task_Salesforce", @numRowsToReturn, "WhoId, callback_detail__c ", "WhoId", @subkey) 
    set @rowCount = rowcount(@rows)
    set @link = 'http://cloud.mail.papernest.com/creneau_rappel'


Here is the ampscript used in the landing page :

%%[ var @subkey, @rows 
set @subkey = Requestparameter("_subscriberkey") 
set @rows = Lookup("ENT.Task_Salesforce", "WhoId", "WhoId", @subkey) ]%%

%%[var @result
set @result = UpdateSingleSalesForceObject ('Task', @subkey, 'callback_detail__c', 'immediate_callback')

But, when the lead lands on this landing page, nothing happens, the field callback_Detail__c does not take the value "immediate_callback".

Why is it not working?

1 Answer 1


Firstly, there shouldn’t be space between function name and parentheses:

%%[var @result
set @result = UpdateSingleSalesForceObject('Task', @subkey, 'callback_detail__c', 'immediate_callback')

Also keep in mind that updateSingleSalesforceObject does not update the data extension directly, but uses Marketing Cloud Connector to update the record directly on a Sales Cloud object. The way you phrase your question, it sounds to me you expect the data extension to be updated directly.

There is up to 15 minute latency between a record is updated in Sales Cloud and the corresponding synchronised data extension is updated. If you wait before checking the data extension, the value will eventually be updated.

  • Thanks a lot Lukas for your help ! Well, I have updated the function but, it is still not working...
    – Clothilde
    Aug 19, 2019 at 16:30

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.