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 Apps / Updating multiple rows...
Power Apps
Answered

Updating multiple rows at the same time

(1) ShareShare
ReportReport
Posted on by

Hi,

I have a table named "Automobile" where I have different columns ID, DPT and Department.  I have to update the multiple rows  in "Department" which has same value in another column "DPT". I need help for getting each steps to update multiple rows at the same time. For example: 

 

IDDPTDepartment
1HR 
2HR 
3HR 
4CLM 
5CLM 
6CLM 
7MKT 
8FIN 
9FIN 
10FIN 
11FIN 
12FIN 

 

It should be updated like:

IDDPTDepartment
1HRHuman Resource
2HRHuman Resource
3HRHuman Resource
4CLMClaim
5CLMClaim
6CLMClaim
7MKTMarketing
8FINFinance
9FINFinance
10FINFinance
11FINFinance
12FINFinance

 

Categories:
I have the same question (0)
  • Daniel Bocklandt Profile Picture
    5,151 Super User 2026 Season 1 on at

    Hey @Ansu8371 ,

     

    To achieve this you would need a ForAll Loop. Be Aware, This will go through every Record in your table and update it

    If you ant to do it only for some, we will need to adapt the formula.

    ClearCollect(colAuto,Automobile);
    ForAll(colAuto,
     Pacth(Automobile,
     ThisRecord,
     {Department:Switch(ThisRecord.DPT, "HR", "Human Resource","CLM", "Claim", "MKT", "Marketing", "FIN","Finance)})) 

     

    Let me know if you have any questions. 

     

  • Ansu8371 Profile Picture
    on at

    Thanks for the quick response DBO_DV.

    I apologize if I haven't described clearly, my scenario is quite different, I have 20,000 rows of records and have 300 distinct values for the field which I need to update  and not possible to use the above formula. 

  • Verified answer
    Daniel Bocklandt Profile Picture
    5,151 Super User 2026 Season 1 on at

    Do you have a filter with whom you can limit those entries? Maybe if the department column is empty? 

  • Ansu8371 Profile Picture
    on at

    Thank you, it works now. I have used the following formula:

     

    ClearCollect(
    RecordsToUpdate,
    Filter(
    'dbo.Automobile',
    DPT = DPTValue.Text
    )
    );
    ForAll(
    RecordsToUpdate,
    Patch(
    'dbo.Automobile',
    ThisRecord,
    {Department: DepartmentValue.Text} // Use the text input value
    )
    );

    PowerBIIntegration.Refresh(); Notify("Records updated successfully", NotificationType.Success);

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

Congratulations to the June Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 337 Most Valuable Professional

#2
11manish Profile Picture

11manish 173

#3
Valantis Profile Picture

Valantis 86

Last 30 days Overall leaderboard