Announcements
Hi - I have a screen with one drop down button and multiple text fields (say 6). When a drop down value is chosen, text fields will be auto populated and the user can update any of these text fields. this is all working fine. But I do not know how to update this particular record in data source table. I am not using form, the drop down and text input values are just on the screen.
Hi @Anonymous
You can use the Patch function for this: Patch function in Power Apps (contains video) - Power Apps | Microsoft Docs
Patch( dbList, LookUp(dbList, ID = 1), //finding the record to update { Field1 = textinput1.Text, Field2 = dropdown.Selected.Value, ... } );
Adding a new record in the db:
Patch( dbList, Defaults(dbList), { Field1 = textinput1.Text, Field2 = dropdown.Selected.Value, ... } );
Hope this helps!
Hi @SkiDK - Inserting new record worked with Patch. But I need to update existing record.
But I am getting error when trying to update existing record. here is what I am doing -
Patch(table1,LookUp(table1,'Content.InvoiceId'= Dropdown2.Selected.'Content.InvoiceId'){'Content.Customer':TextInput1.Text,'Content.Owner':TextInput2.Text,'Content.Vendor':TextInput3.Text,'Content.PurchaseOrderId':TextInput4.Text,'Content.InvoiceDate':TextInput5.Text}) ;
Error I am getting -
@Anonymous ,
You have two threads going on the same issue - I responded to the other one here
The below worked for me when I used either dropdown or combo box -
Patch( ConsumerList,
LookUp(ConsumerList,'Content.InvoiceId'=ComboBox1.Selected.'Content.InvoiceId'),
{'Content.Customer':TextInput1_1.Text,'Content.Owner':TextInput2_1.Text,'Content.Vendor':TextInput3_1.Text,
'Content.PurchaseOrderId':TextInput4_1.Text,'Content.InvoiceDate':TextInput5_1.Text});
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.
Congratulations to our community stars!
Expanding mentorship, skilling, and AI innovation
These are the community rock stars!
Stay up to date on forum activity by subscribing.
11manish 360 Super User 2026 Season 2
M Bilal Khan 325
Mohsin Ali 232