Showing results for 
Search instead for 
Did you mean: 
Advocate II
Advocate II

LookUp after Patch (creating a new record) returns incomplete record for SQL

After calling a Stored Procedure (via PowerAutomate) to create a new record in an Azure SQL, I check that the return is successful and if so, I call LookUp() to retrieve the newly created record.


This all works fine except that the record returned by LookUp() doesn't return all the columns in the row. It returns a record, but only with 4 columns, not the 9 it should have. Paraphrasing, I do something like this:


Set( tmpNewRecordID , SPU_CreateRecord.Run( A, B, C));

If ( tmpNewRecordID > 0,

  Set( gCurrentRecord, LookUp( Records, pkRecord = tmpNewRecordID ));


The record returned by the LookUp() only has 4 columns (A,B,F,G) but it should have 9. The other 5 coluns are populated by the stored procedure. I even inserted a Refresh(Records) statement between the Stored Proc run and the LookUp() statement and this resulted in 5 columns being returned, but not the full 9. Note that the same LookUp() works properly once we navigate away from this screen and run the LookUp() again on another screen.


Strangely, for one of the missing columns, the PowerApps Studio variable inspector reports a blank value, even though a text label is reporting its value correctly. For another missing column, a text label reports blank as does the Studio.


Is this a timing issue? Or a bug with the Flow/SQL connectors...




EDIT: After a lot of research on other sites, I can confirm this is a bug with PowerApps/SQL Connector interaction. It was reported at least as early as 2018 by @Meneghino on his blog. It's particularly evident when there is a column of type "Date" in the SQL table. Please fix it Microsoft.

Super User
Super User

Hi @MarrinerDev 


  • Can you explain when the Power Automate will be triggered?
    • Are we creating a new record on another table when powerapps updates on one table?
  • For powerapps, What is your datasource?


The PowerAutomate Flow to call the Stored Proc is triggered manually on a button click by the user to create a new record. It works fine and the the row in the table is created as expected.

The Stored Proc creates a new row in one table only. The data source is Azure SQL which is accessed via the Microsoft SQL Server Connector.

Helpful resources

Power Platform Conf 2022 768x460.jpg

Join us for Microsoft Power Platform Conference

The first Microsoft-sponsored Power Platform Conference is coming in September. 100+ speakers, 150+ sessions, and what's new and next for Power Platform.

365 EduCon 768x460.png

Microsoft 365 EduCon

Join us for two optional days of workshops and a 3-day conference, you can choose from over 130 sessions in multiple tracks and 25 workshops.

Users online (3,247)