QuestionQ20

VerifiedTransform and format data with DataWeave

A function named toUpper must be defined that accepts a string named userName and returns the string in uppercase.

What is the correct DataWeave code for defining the toUpper function?

Explanation

DataWeave defines named functions with the form fun functionName(parameters) = expression. The upper function converts a string to uppercase. In executable code, the identifier passed to upper must exactly match the declared parameter because DataWeave identifiers are case-sensitive.

Learn more

Community Discussion

No comments yet. Be the first to start the discussion!