Showing results for 
Search instead for 
Did you mean: 
Level 8

Patch to clear a time field?

I am trying to clear (null) a time field in SQL. I have a Patch:

Patch(SQLTable, Defaults(SQLTable),
{SignoutTime: Text(Now(),"[$-en-US]hh:mm:ss")})

Sometimes my users make mistakes so I need to be able to cancel that action by clearing data in SQL Table with time(7) data type. I tried:

Patch(SQLTable,LookUp(SQLTable,DailyAttUID = User_x0020_ID && 'AttendanceDate String' = TodayVar),
{SignoutTime: Blank()})

That didn't seem to work. Not sure what or how to clear this field out? Any Suggestions?

Level: Powered On

Re: Patch to clear a time field?

@BrianHFASPS Can you try 

Patch(SQLTable,LookUp(SQLTable,DailyAttUID = User_x0020_ID && 'AttendanceDate String' = TodayVar),
{SignoutTime: ""})

instead of Blank() use "".

Community Support Team
Community Support Team

Re: Patch to clear a time field?

Hi @BrianHFASPS ,

Do you want to clear time field value within your SQL Table using Patch function?


It is an known issue with Patch function within PowerApps -- we could not patch a Blank (null) value to a time field in SQL Table using Patch function directly.


As an alternative solution, please consider turn on the "Formula-level error management" option within Advanced settings of App settings of your app firstly, then try your Patch formula again, check if the issue is solved.1.JPG


Please check and see if the following blog would help in your scenario:


Best regards,

Community Support Team _ Kris Dai
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Helpful resources

New Ranks and Rank Icons in April

'New Ranks and Rank Icons in April

Read the announcement for more information!

Better Together’ Contest Finalists Announced!

'Better Together’ Contest Finalists Announced!

Congrats to the finalists of our ‘Better Together’-themed T-shirt design contest! Click for the top entries.

Power Platform 2019 release wave 2 plan

Power Platform 2019 release wave 2 plan

Features releasing from October 2019 through March 2020


Community Summit North America

Innovate, Collaborate, Grow - The top training and networking event across the globe for Microsoft Business Applications

Top Solution Authors
Top Kudoed Authors
Users online (4,090)