How to filter a JSON object with dynamic keys with Power Automate

  Рет қаралды 7,459

Paul Murana

Paul Murana

Жыл бұрын

This video explains how to filter a JSON object in #powerautomate which has dynamic key value pairs. Because the filter array action expects you to know the key name before you can filter on it, this can be difficult to achieve.
This technique is one that I haven't used before so I thought it was interesting to share. The original forum post is here:
powerusers.microsoft.com/t5/B...

Пікірлер: 27
@joti8818
@joti8818 Жыл бұрын
Brilliant solution! Thank you very much for sharing!
@jasonbuchek
@jasonbuchek Ай бұрын
100% like everyone else has said, you are the man sir! Subbing now
@tuhan4780
@tuhan4780 7 ай бұрын
Hey, thank you for sharing this solution, was really struggling with same problem!(Property names for me were dynamic dataverse IDs which I needed to updated, and keys were True\false values defining if this ID needs an update) For anyone who would come across this solution I`ll post all formulas down here: createArray(body('Post_Card')['data']) split(trim(body('Create_CSV_table')),decodeUriComponent('%0D%0A')) range(0,length(split(outputs('Split_CSV')[0],','))) split(outputs('Split_CSV')[0],',')[item()] split(outputs('Split_CSV')[1],',')[item()]
@EnlightenedOne90
@EnlightenedOne90 Жыл бұрын
Another great vid Paulie, thank you! Will be adding this solution to my toolbox for future use.
@PaulieM
@PaulieM Жыл бұрын
Thank you Jeremy! This was a tricky one!
@nguyenmanhtuan1772
@nguyenmanhtuan1772 3 ай бұрын
Thank you very much Sir. You have always been one of the most of my favorite channels when I seek solutions for my concerns. I am lucky to know your channel.
@PaulieM
@PaulieM 3 ай бұрын
That’s very kind of you, thank you! 🙏
@joel.engelhardt
@joel.engelhardt Жыл бұрын
Hey, thank you for sharing this! I was scratching my head for a while trying to figure this out, and this is the EXACT solution I needed. I'm needed this exact solution to process the key-value pairs from the "Get changes for an item or a file" action. Thank you! You're very generous.
@PaulieM
@PaulieM Жыл бұрын
You're very welcome!
@RealIndianEmotion
@RealIndianEmotion Жыл бұрын
Saved the day, Many thanks!
@codelessstudio1269
@codelessstudio1269 4 ай бұрын
Exactly what i'm looking for, thanks for sharing Paul :)
@PaulieM
@PaulieM 4 ай бұрын
Great to hear!
@lubeshbehera1993
@lubeshbehera1993 Жыл бұрын
woah impressive !!!
@bluric0
@bluric0 9 күн бұрын
Didn't work for me unfortunately. It looks like my outputs contain nested arrays that are also split with comma so not sure how to get around that!
@navarrocloud
@navarrocloud Жыл бұрын
Very nice hack.
@mr_grucha
@mr_grucha Жыл бұрын
Best hack I have ever seen
@neeltiwari6147
@neeltiwari6147 2 ай бұрын
If i have output of parse jason like this { data: { “data1”:”one”, “data2”:””, “data3”:”data3” } } now you can see data two value is just empty “” so i want to remove data two and want output like this { data: { “data1”:”one”, “data3”:”data3” } } how to achieve this for you have any idea?
@bluric0
@bluric0 9 күн бұрын
Will this work with complex JSON that includes Objects and Arrays with objects? I am going to give it a go, but essentially depending on the config of said item, the output of JSON Objects and arrays change continuously. I am trying to work out a method to dynamically update the outputs for all values that do not contain null into a word document. Essentially the end goal is creating documentation for the config itself. If your interested to give it a go, let me know and I can send you a sample of some data I have, but essentially the output will come directly out of a HTTP REST API.
@davidezequielmonti663
@davidezequielmonti663 7 ай бұрын
Hey, nice video! How could you do to go backwards? I mean, going from that Array to a dynamic key value pairs object? Thanks a lot!
@PaulieM
@PaulieM 7 ай бұрын
Do you have an example input and desired output you can provide?
@matiaskezman1
@matiaskezman1 Жыл бұрын
Hello, thank you for sharing. Do you have any suggestions on the following scenario: my json has comments data which mesns that I could have a comma in the text. The comma split doesn't work in this scenario.
@PaulieM
@PaulieM Жыл бұрын
It’s always tricky in this case. I’d be interested to take a look at it with you.
@matiaskezman1
@matiaskezman1 Жыл бұрын
@@PaulieM Thank you for responding. How would you like to connect ? I'm currently working on a way to do this using xpath, but having a hard time with getting the values (I've got the keys correctly). Your suggestions are much appreciated!
@PaulieM
@PaulieM Жыл бұрын
@@matiaskezman1 please fill in the contact form on my blog.
@kylecarnaroli5062
@kylecarnaroli5062 Жыл бұрын
Great Tutorial, wish it helped with my situation, but unfortunately there are commas inside of the dynamic keys and this throws the split off.
@PaulieM
@PaulieM Жыл бұрын
Would be interested in having a look at your sample.
Unlock the Full Potential of Parse JSON in Power Automate
19:47
Paul Murana
Рет қаралды 2 М.
Alex hid in the closet #shorts
00:14
Mihdens
Рет қаралды 13 МЛН
БАБУШКИН КОМПОТ В СОЛО
00:23
⚡️КАН АНДРЕЙ⚡️
Рет қаралды 15 МЛН
Now THIS is entertainment! 🤣
00:59
America's Got Talent
Рет қаралды 40 МЛН
Каха заблудился в горах
00:57
К-Media
Рет қаралды 3,4 МЛН
Remove / delete data from a CSV file using Power Automate
6:14
AMD Almost Went Bankrupt…but were saved by Sony and Microsoft?
5:35
How to write expressions in Power Automate
18:31
DamoBird365
Рет қаралды 10 М.
How to parse a CSV file with Power Automate
8:04
Paul Murana
Рет қаралды 35 М.
He Got A Surprise Ice Cream🤠🤪
0:44
BorisKateFamily
Рет қаралды 11 МЛН
Готовим дошик-ролл за решеткой... с @samsebesushist
0:40
Кушать Хочу
Рет қаралды 2,9 МЛН
не так кладёшь #карелия #рыбалка #природа #сегозеро
0:13
Север - Родина смелых
Рет қаралды 2,7 МЛН
Small Act of Kindness is also a charity
1:00
PainCare _Trust
Рет қаралды 20 МЛН
Amazing 3 iPhone Trick Shot
0:32
That's Amazing Shorts
Рет қаралды 88 МЛН
Don´t WASTE FOOD pt.2 🍕
0:19
LosWagners ENG
Рет қаралды 57 МЛН