QuestionQ9

VerifiedDeveloping Mule Applications

Refer to the exhibit.

Which DataWeave expression transforms the sample XML input into the CSV output?

Question Image

Explanation

DataWeave’s multi-value selector .*item returns all repeated item elements, allowing map to create one CSV record per item. XML attributes must be accessed with the attribute selector, such as value.@saleId and value.@itemId. The calculated value.price * value.quantity produces the required item prices.

Learn more

Community Discussion

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