Skip to main content
added 512 characters in body
Source Link
Rachid Mamai
  • 4.7k
  • 1
  • 12
  • 27

You can use UpdateSingleSalesforceObject to update data on Sales/Service Cloud. This is an example from the doc:

%%[
var @result
set @result = UpdateSingleSalesforceObject('Lead','00Q00003yAEj','Email','[email protected]')
]%%

The system updates the Email field on the Lead with ID 00Q00003yAEj to contain [email protected].

To retreive data, you need to use the RetrieveSalesforceObjects function. It returns a rowset that you can loop through..

Returns a rowset with the selected information from Salesforce objects that match the criteria you specify. This function works only with an account integrated with a Salesforce account. Include multiple sets of ordinals 3, 4, and 5 to retrieve information as necessary. Because this function returns data as a rowset, use Row() and Field() to evaluate the data.

Example: The system returns the first name and last name of all leads in your Salesforce account where the region equals west:

%%[ var @rs
Set @rs= RetrieveSalesforceObjects('Lead', 'Id, FirstName,LastName', 'region', '=', 'west','AnnualRevenue', '>', '1000000')
]%%

Reference:

UpdateSingleSalesforceObject

RetrieveSalesforceObjects

You can use UpdateSingleSalesforceObject to update data on Sales/Service Cloud. This is an example from the doc:

%%[
var @result
set @result = UpdateSingleSalesforceObject('Lead','00Q00003yAEj','Email','[email protected]')
]%%

The system updates the Email field on the Lead with ID 00Q00003yAEj to contain [email protected].

Reference:

UpdateSingleSalesforceObject

You can use UpdateSingleSalesforceObject to update data on Sales/Service Cloud. This is an example from the doc:

%%[
var @result
set @result = UpdateSingleSalesforceObject('Lead','00Q00003yAEj','Email','[email protected]')
]%%

The system updates the Email field on the Lead with ID 00Q00003yAEj to contain [email protected].

To retreive data, you need to use the RetrieveSalesforceObjects function. It returns a rowset that you can loop through..

Returns a rowset with the selected information from Salesforce objects that match the criteria you specify. This function works only with an account integrated with a Salesforce account. Include multiple sets of ordinals 3, 4, and 5 to retrieve information as necessary. Because this function returns data as a rowset, use Row() and Field() to evaluate the data.

Example: The system returns the first name and last name of all leads in your Salesforce account where the region equals west:

%%[ var @rs
Set @rs= RetrieveSalesforceObjects('Lead', 'Id, FirstName,LastName', 'region', '=', 'west','AnnualRevenue', '>', '1000000')
]%%

Reference:

UpdateSingleSalesforceObject

RetrieveSalesforceObjects

Source Link
Rachid Mamai
  • 4.7k
  • 1
  • 12
  • 27

You can use UpdateSingleSalesforceObject to update data on Sales/Service Cloud. This is an example from the doc:

%%[
var @result
set @result = UpdateSingleSalesforceObject('Lead','00Q00003yAEj','Email','[email protected]')
]%%

The system updates the Email field on the Lead with ID 00Q00003yAEj to contain [email protected].

Reference:

UpdateSingleSalesforceObject