cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Community Champion
Community Champion

Re: Ability to patch null values, any update?

Hi @tianaranjo

 

Have you followed the instructions here?

https://powerapps.microsoft.com/en-us/blog/new-feature-error-handling-and-writing-null-values-to-dat...

 

Specifically you need to Patch a Blank() and also turn on error handling.  It works with Azure SQL Database but I have not tested with SharePoint lists.

Highlighted
Continued Contributor
Continued Contributor

Re: Ability to patch null values, any update?

@Meneghino  Thanks for your reply. I have tried following the instructions from this link with no luck.  Would you mind sending me an example of your Patch formula?

Highlighted
Community Champion
Community Champion

Re: Ability to patch null values, any update?

With Azure SQL Database this works:

 

Patch('[dbo.mytable]', {ID: 123}, {MyColumn:Blank()})

Where 123 is just a record where MyColumn is currently not null.  The patch makes MyColumn's value null for record with ID 123.

ID is just an int column of mytable which is also the primary key

Highlighted
Continued Contributor
Continued Contributor

Re: Ability to patch null values, any update?

@Meneghino  As always; thanks!  One more question, what if the column is not blank because the Status is Closed.  How do I Patch the date for the same column?

Highlighted
Continued Contributor
Continued Contributor

Re: Ability to patch null values, any update?

@Meneghino  No luck with this one.  Any other suggestions?

 

Thank you!

Highlighted
Continued Contributor
Continued Contributor

Re: Ability to patch null values, any update?

Hoping to raise this again - has anybody patched a Blank() date back to a SP list after a date had previously been submitted?  I have an 'In Progress' and 'Closed Status column.  If Closed, a Date Closed is submitted.  However, the issue could be re-opened if customer not satisfied with action.  When I switch back to 'In Progress' status, I can make the DateClosed column 'appear' blank, however, OnSubmit, it is storing the initial DateClosed date.  

@Meneghino

@lesaltzm

Highlighted
Helper I
Helper I

Re: Ability to patch null values, any update?

 

hello @tianaranjo Tried with SQL... doesn't worked at all but I use datevar=0.... it works

Kind regards

Highlighted
Helper III
Helper III

Re: Ability to patch null values, any update?

Have you found a solution for this ? I am trying to Patch people picker field but it is throwing error when field doesnt have value .  

 

Thanks in advance .

Highlighted
Frequent Visitor

Re: Ability to patch null values, any update?

Hi, @Yemata

I try to do this Blank() function like this


Patch(SQL, LookUp(SQL, ID = Value), { Approved_Date: Blank() } );

So .. this is not work. I have no idea for this thing

Highlighted
Helper III
Helper III

Re: Ability to patch null values, any update?

 

I used Submit form instead of patch . It worked fine. 

One my button OnSelect 

SubmitForm(FormRequest);
Navigate( FormSubmited, ScreenTransition.Fade)

Helpful resources

Announcements
August 2020 Community Challenge: Can You Solve These?

August 2020 Community Challenge: Can You Solve These?

We're excited to announce our first cross-community 'Can You Solve These?' challenge!

secondImage

Return to Workplace

Reopen responsibly, monitor intelligently, and protect continuously with solutions for a safer work environment.

secondImage

Super Users Coming in August

We are excited for the next Super User season.

secondImage

Community User Group Member Badges

FIll out a quick form to claim your community user group member badge today!

secondImage

Power Platform 2020 release wave 2 plan

Features releasing from October 2020 through March 2021

Top Solution Authors
Top Kudoed Authors
Users online (5,712)