PLAT-DEV-210 practice question 1 of 25

A developer creates a DataRaptor Extract to retrieve data to pass to an external service. The external service expects the field value to be an integer. However, the DataRaptor is sending it as a string. Which action can the developer take to fix this?

Full set: 103 questions
Answer options
A: In the DataRaptor Output tab, select the Output Data Type of that field to Integer.
B: In the DataRaptor Output tab, enter the default value as 0 on the field.
C: In the DataRaptor Extract tab, set the Input Data Type field to Integer.
D: In the DataRaptor Formula tab, define a formula using the function TOINTEGER and use the formula as output. Correct answer
Correct Answer:
D. In the DataRaptor Formula tab, define a formula using the function TOINTEGER and use the formula as output.
Explanation

The most appropriate and explicit method to perform data type conversion within a DataRaptor is by using the Formulas tab. This tab is specifically designed for data transformation and manipulation. The TOINTEGER function is provided for this exact purpose: it takes an input value (in this case, a string) and converts it into an integer. The result of this formula can then be mapped in the Output tab, ensuring the data sent to the external service conforms to the required integer data type.

Why Incorrect

A. While the Output Data Type setting can cast a value, using a formula is the more robust and explicit method for data transformation, which is the primary purpose of the Formulas tab.
B. Setting a default value only applies if the source field is null. It does not convert the data type of an existing non-null string value (e.g., "123").
C. The Input Data Type on the Extract tab is used to define the data type for filter criteria (e.g., in a WHERE clause), not to transform the data that is retrieved and returned.

References

1. Salesforce Help

OmniStudio

DataRaptor Functions: The TOINTEGER function is documented as the standard method for data type conversion. "TOINTEGER(String/Number/Boolean): Converts a value to the Integer data type." This confirms that using a formula is the designated approach for this transformation.

2. Salesforce Help

OmniStudio

Define Formulas in a DataRaptor: "You can define formulas in a DataRaptor to add new

transformed

or calculated values to the data structure." This establishes the Formulas tab as the correct location for transformation logic.

3. Salesforce Help

OmniStudio

Map DataRaptor Extract Output to JSON Output: This document describes the Output tab's functionality. While it mentions the Output Data Type field for casting

the primary and more powerful tool for transforming data

including type conversion

is the Formulas tab with its extensive function library.

Scroll to Top