cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Danielamgzz
Regular Visitor

It is possible to add an item from Power apps to SQL table?

Im new in Power Apps so i don know if its posible to add an item to a SQL Table from power apps, please help!

1 ACCEPTED SOLUTION

Accepted Solutions
RandyHayes
Super User
Super User

@Danielamgzz 
To add a little more to @Pstork1 's comments - it looks like you might not have a primary key on your table as all of the fields you have in your form are showing as View only.  This is PowerApps' way of telling you it cannot write to the table...must have a primary key defined for it!

_____________________________________________________________________________________
Digging it? - Click on the Thumbs Up below. Solved your problem? - Click on Accept as Solution below. Others seeking the same answers will be happy you did.
NOTE: My normal response times will be Mon to Fri from 1 PM to 10 PM UTC (and lots of other times too!)
Check out my PowerApps Videos too! And, follow me on Twitter @RandyHayes

Really want to show your appreciation? Buy Me A Cup Of Coffee!

View solution in original post

4 REPLIES 4
Pstork1
Dual Super User
Dual Super User

Yes you can Insert or Update records in a SQL table using Power Apps.  It does require a premium license and there are some prerequisites to the way the table is created that apply.  But it is normally possible.  Here's documentation.

Connect to SQL Server from Power Apps - Power Apps | Microsoft Docs



-------------------------------------------------------------------------
If I have answered your question, please mark your post as Solved.
If you like my response, please give it a Thumbs Up.

Hi @Pstork1 

I already have the connection with SQL, but I do not know how to add the fields of the SQL table to be able to add records

Danielamgzz_0-1637950328201.png

 

Do you want to add new records of update existing records?

To do that you can submit a Form (New or Edit) or use Patch().

 

Take a look at this walkthrough.  Creating a Basic PowerApp Against a SQL Server Table (pragmaticworks.com)



-------------------------------------------------------------------------
If I have answered your question, please mark your post as Solved.
If you like my response, please give it a Thumbs Up.
RandyHayes
Super User
Super User

@Danielamgzz 
To add a little more to @Pstork1 's comments - it looks like you might not have a primary key on your table as all of the fields you have in your form are showing as View only.  This is PowerApps' way of telling you it cannot write to the table...must have a primary key defined for it!

_____________________________________________________________________________________
Digging it? - Click on the Thumbs Up below. Solved your problem? - Click on Accept as Solution below. Others seeking the same answers will be happy you did.
NOTE: My normal response times will be Mon to Fri from 1 PM to 10 PM UTC (and lots of other times too!)
Check out my PowerApps Videos too! And, follow me on Twitter @RandyHayes

Really want to show your appreciation? Buy Me A Cup Of Coffee!

Helpful resources

Announcements
Power Platform Call June 2022 768x460.png

Power Platform Community Call

Join us for the next call on August 17, 2022 at 8am PDT.

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 (2,647)