Reputation: 23
This is what the expression looks like
I need to get the substring teBatches_raw to only return everything before the _ character.
Expected output
teBatches
Upvotes: 2
Views: 8402
Reputation: 14399
Azure Data Factory (ADF) and Synapse Pipelines have an expression language with a number of functions that can do this type of thing. You can use split
for example to split your string by underscore (_) into an array and then grab the first item from the array, eg something like:
@{split(pipeline().Pipeline, '_')[0]}
Or with a variable, not using string interpolation:
@split(variables('varInput'), '_')[0]
My results for the variable line:
Upvotes: 3