Skip to main content

Notifications

Community site session details

Community site session details

Session Id :
Power Apps - Power Apps Experimental Features
Unanswered

Unable to access response from stored procedure when assigning to a property using Power FX

(1) ShareShare
ReportReport
Posted on by 2
I am trying to execute a SQL Server stored procedure from power apps. The Power FX command I am using is DBName.Stored_Procedure().ResultSets.Table1
But I am not able to access the Table1 or the ResultSets. I tried assigning it to a collection but nothing seems to be returned. 
Surprisingly when I use the monitor I see that the Response Tab does have the expected response:
"body": {
    "ResultSets": {
      "Table1": [
        {....
So the stored procedure is working and it is getting executed as well as expected. But something wrong with accessing the response. 
This seems to be an issue for many people as seen in some youtube comments on tutorial videos on the same. Is there a fix to this? Or am I doing something wrong here?
  • MB-23070938-0 Profile Picture
    46 on at
    Unable to access response from stored procedure when assigning to a property using Power FX
    You need to give the power FX a detailed list of what results you're expecting. As per documentation https://learn.microsoft.com/en-us/power-apps/maker/canvas-apps/connections/connection-azure-sqldatabase
     
    Set(
        <MyUntypedObject>,
        <datasourceName>.<StoredprocedureName>( 
          { <paramName1>: "someString" }
        ).ResultSets
    );
    Set(
        table1,
        <MyUntypedObject>.Table1
    );
    Set(
        TypedTable,
        ForAll(
            table1,
            {
                BookID: Value(ThisRecord.BookID),
                BookName: Text(ThisRecord.BookName)
            }
        )
    );
     
  • Michael E. Gernaey Profile Picture
    42,278 Super User 2025 Season 1 on at
    Unable to access response from stored procedure when assigning to a property using Power FX
    Hi
     
    Is this a Model Driven or Canvas App
     
    Are you trying to access via a Connector, or are you using Power Automate?
     
    Please share the code that you are having an issue with and the error it is giving you.
     
    Power Apps don't simply "access" JSON things, so I have no idea how you are trying because you didn't share

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

🌸 Community Spring Festival 2025 Challenge Winners! 🌸

Congratulations to all our community participants!

Warren Belz – Community Spotlight

We are honored to recognize Warren Belz as our May 2025 Community…

Congratulations to the April Top 10 Community Stars!

Thanks for all your good work in the Community!

Leaderboard > Power Apps - Power Apps Experimental Features

#1
mmbr1606 Profile Picture

mmbr1606 17 Super User 2025 Season 1

#2
stanmiller95 Profile Picture

stanmiller95 16

#3
MS.Ragavendar Profile Picture

MS.Ragavendar 14

Overall leaderboard

Featured topics