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 / Set all values in a sh...
Power Apps
Answered

Set all values in a sharapoint column to 0

(0) ShareShare
ReportReport
Posted on by Microsoft Employee

Hi,

 

i´m trying to create a button which clears/set a whole column in a sharepoint list to blank or 0. I´ve tried using the patch function but i cant get it to work or dont know what to fill in. 

 

I´ve created a patch function for "ThisItem" before but dont know how to change it to a whole column so that all entries get patched.

Categories:
  • Verified answer
    PowerRanger Profile Picture
    3,458 Super User 2024 Season 1 on at
    SampleList, ForAll( SampleList As _item, { ID: _item.ID, request: "" } ) )

     

    Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.

    @Anonymous Please have a look at the formular below.

     

    This will set the column "request" to "" (Empty). The DataSource in the example is called SampleList

     

    Patch(
                          
  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

    Yes thanks that worked i couldnt get it to work with "" for blank but instead just 0 worked for me

  • RandyHayes Profile Picture
    76,299 Super User 2024 Season 1 on at

    @Anonymous 

    You can also utilize the UpdateIf function for this.

    UpdateIf(youirList, true, {columnX: Blank()})  will set the columnX in ALL records to Blank().

     

    However, in order to set a field to a blank value, you NEED to have the Formula-level error management feature turned on in your app feature settings.  This is why you couldn't get "" to work.

     

    I hope this is helpful for you.

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

Leaderboard > Power Apps

#1
11manish Profile Picture

11manish 354 Super User 2026 Season 2

#2
M Bilal Khan Profile Picture

M Bilal Khan 320

#3
Mohsin Ali Profile Picture

Mohsin Ali 246

Last 30 days Overall leaderboard