How to do length validation in Mule Dataweave
%dw 1.0
%output application/xml
---
(payload default []) map {
Field1:$.Field11,
Field2:$.Field22,
Field3:$.Field33,
Field4:$.Field44
}
I want to do validation like max Length of Field22 < 20
How to achieve this in Mule Dataweave