cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
drako
Helper I
Helper I

Can get Aggreagte to work in SQL connector

Hi,

   I'm using the SLQ conector. My query works great wihtout issues but when I try to use the aggregate option the flow crashes. This is whta I have set up:

 

drako_0-1613153502574.png

 

   The aggregate is: aggregate(Minutes with sum as TotalMinutes)

   Minutes is a SQL field as decimal thta I want to sum. I have not been able to egt this to work...any ideas? Also is their a way to GroupBy?

 

Kind Regards

 

 

3 REPLIES 3
abm
Super User III
Super User III

Hi @drako 

 

I have tested this with my local sql server and Azure SQL server. Both did worked for me. Most likely the error is related to your filter query.

 

 

image.png



Did I answer your question? Mark my post as a solution!

If you liked my response, please consider giving it a thumbs up


Proud to be a Flownaut!

Learn more from my blogPower Automate Video Tutorials

Hi @abm , I had thought of this also...if I remove the aggregate the query works...so the filter is fine... could it be that these don't work together...you can only an aggregate or a filter?

abm
Super User III
Super User III

Hi @drako 

 

Yes looks like currently there are no support for aggregate against filter conditions. Your other option is try this directly under as a SQL query and expose that as a sql stored procedure. So when you calling from Power Automate you can pass those filter query parameter values to SQL SP.

 

Thanks



Did I answer your question? Mark my post as a solution!

If you liked my response, please consider giving it a thumbs up


Proud to be a Flownaut!

Learn more from my blogPower Automate Video Tutorials

Helpful resources

Announcements
MPA User Group

Welcome to the User Group Public Preview

Check out new user group experience and if you are a leader please create your group

MSFTBizAppsLaunchEvent

Experience what’s next for Power Virtual Agents

See the latest Power Automate innovations, updates, and demos from the Microsoft Business Applications Launch Event.

New Super Users

Meet the Power Automate Super Users!

Many congratulations to the Season 1 2021 Flownaut Crew!

Power Platform ISV STudio

Power Platform ISV Studio

ISV Studio is the go-to Power Platform destination for ISV’s to monitor & manage applications post-AppSource publish.

Users online (73,316)