question

NandanHegde-7720 avatar image
0 Votes"
NandanHegde-7720 asked ShaikMaheer-MSFT answered

Exclude certain elements from Array

Hey,
I have an variable of type Array as seen below :

143648-image.png

I need to copy that value as string in another variable of type:String excluding Column values.

Note: the array is random and the only thing which is same is Column value and all other value names can be random like type etc.

So how to exclude that particular element

azure-data-factory
image.png (9.3 KiB)
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

1 Answer

ShaikMaheer-MSFT avatar image
0 Votes"
ShaikMaheer-MSFT answered

Hi @NandanHegde-7720 ,

Thank you for posting query on Microsoft Q&A Platform.

Assuming your column values always be in first position of array. If would like to take "type:int64" key value as string in to another variable? If yes you can try to use below expression.
@string(variables('<array variable name>')[1])

If you there is no guarantee that Column key will be in first position, then may be consider taking all array values as string in variable and then use replace() function to replace column values with empty.

Hope this will help. Please let us know if any further queries.


  • Please don't forget to click on 130616-image.png or upvote 130671-image.png button whenever the information provided helps you. Original posters help the community find answers faster by identifying the correct answer. Here is how

  • Want a reminder to come back and check responses? Here is how to subscribe to a notification

  • If you are interested in joining the VM program and help shape the future of Q&A: Here is how you can be part of Q&A Volunteer Moderators

5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.