web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / Unable to Execute Stor...
Power Automate
Answered

Unable to Execute Stored procedure

(0) ShareShare
ReportReport
Posted on by 8

Hello All, 

 

I am attempting to generate some data for my Flow by executing a stored procedure.  I have created a gateway on a Windows server running SQL 2012, which allows a connection to a database instance. 

 

I am able to return table names and rows for this database without any issue.  When I select the option to execute the stored procedure I am unable to generate a list of procedures and am presented with an "Unknown Error".  Manually specififying the procedure name does not work.  

 

Screenshot: http://imgur.com/a/jwxds

 

I am able to log into SSMS using the credentials supplied for the gateway / connection and execute the procedure without issue.  However I "feel" like there is a permission issue that is preventing the flow engine from reading the object / container that is holding the stored procedures, but I don't know where to look.

 

Any help or direction with this would be much appreciated!


Regards, 

 

Peter Burton

Categories:
  • Verified answer
    Sunay Profile Picture
    Microsoft Employee on at

    Hi @PeterBurton,

    Stored procedures are unfortunately not supported while using a Gateway. We are working on supporting this functionality and will keep you updated as soon as its ready.

     

    Thanks,

    Sunay

  • PeterBurton Profile Picture
    8 on at

    Hey Sunay, 

     

    Thanks for confirming.  Is there any indication of the time frame around when a feature of this nature is expected to be implemented or is this unknown at this stage?

     

    Also you mentioned it is unsupported using a gateway.  I am a little confused by this, as I couldn't see how you would be able to direct Flow to a database with a stored proc, other than using a gateway?  Is there a way to self host Flow or equivalent to bypass this requirement? 

     

    Regards,

     

    Peter

  • jaj Profile Picture
    8 on at

    If stored procedures are not supported, which SQL operations are supported? Is "add a row" supported?

  • newsomaj Profile Picture
    5 on at

    Yes, I am unable to get the sql connections using a gateway working at all 😞

  • jaj Profile Picture
    8 on at

    Hi Newdomaj,

     

    I managed to make insert row work. The wizard lists the columns available to from the table.

    Consider:

    1) Ensure the Account you use has reader/writer access to the database and table

    2) Ensure you create a connection in flow. You cannot share a connection between powerbi and flow, even though the gateway is shared (thanks DMac)

  • Sunay Profile Picture
    Microsoft Employee on at

    Hey @PeterBurton You can use stored procs for SQL databases that are exposed to Flow via a web endpoint, or if your database is hosted in SQL Azure. Stored procedure support while using a Gateway (https://flow.microsoft.com/en-us/blog/on-premises-data-gateway/) is scheduled to be released by end of November.

     

    Thanks,

    Sunay

  • newsomaj Profile Picture
    5 on at

    Yeah I got it, what threw me off was under add a connection, the sql server authentication type was a free-form field, not the dropdown like i was used to. I typed "Windows" in it, and then everything started to work. Also the username field acted as a password field (showing ******) and so it threw me for a loop.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Leaderboard > Power Automate

#1
Mohsin Ali Profile Picture

Mohsin Ali 430

#2
11manish Profile Picture

11manish 341 Super User 2026 Season 2

#3
M Bilal Khan Profile Picture

M Bilal Khan 282

Last 30 days Overall leaderboard