cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
dsab81
Microsoft
Microsoft

Using SQL Query Results from the SQL Action used inside a Apply to each

Hi,

I have situation where i have to run a sql query within a 'apply to each' to get some results from the variables within in the 'apply to each' , and pass it down stream to other new action with in the same 'apply to each'

 

But when i do it ,  the SQL objects results are not being shown on the right, when i wanted to use the 'Result Sets' into the compose action ( the last compose action at the end ). 

 

dsab81_0-1622837916296.png

 

The lock here is that the SQL query needs paremetres from the variables within Apply to each , so i cannot move it outside Apply to each.

 

Please suggest an alternative approach? 

 

Can i Setup another flow to run SQL Query  within the apply to each ?

and

whether it would allow me to pass the variable values from this flow to the child flow ?

 

 

 

3 REPLIES 3
PrasadAthalye
Community Champion
Community Champion

Resultsets should be available in compose. Are you not able to see it in dynamic content? I am able to find it...

 

May be you can remove and add the action again...

 

PrasadAthalye_0-1622849238276.png

 

Please Like and Mark this as Answer if it resolves your Issue.

Power Automate Community
dsab81
Microsoft
Microsoft

i could not find the results of sql in dynamic content when i use Execute SQL Query , but works when i use some other action like 'Get rows' etc..

Something strange. as you can see, I am able to get it in dynamic content. Is your connection to action broken? Can you add another action? What happens when you click compose and open dynamic content?

Please Like and Mark this as Answer if it resolves your Issue.

Power Automate Community

Helpful resources

Announcements
 WHAT’S NEXT AT MICROSOFT IGNITE 2022

WHAT’S NEXT AT MICROSOFT IGNITE 2022

Explore the latest innovations, learn from product experts and partners, level up your skillset, and create connections from around the world.

Register for a Free Workshop.png

Register for a Free Workshop

Learn to digitize and optimize business processes and connect all your applications to share data in real time.

Users online (3,495)