Jopsiton
Jopsiton

Reputation: 39

What expression in Cloud Data Fusion (CDAP) wrangler can I use to detect if a field contains only numbers? If so, make it null

I am using the Wrangler plugin in Cloud Data Fusion. I need to perform an expression/condition that allows me to validate if a string field contains only numbers. If so, make those records Null

Upvotes: -1

Views: 186

Answers (1)

Albert Shau
Albert Shau

Reputation: 236

One way to do this is with a custom transform. For example:

set-column :[column name] dq:isNumber([column name]) ? null : [column name]

Upvotes: 1

Related Questions