cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
nvpc
Helper I
Helper I

Passing null date values from excel to SP list

I'm using flow to import an excel table that has some null values in a date column. If values are null, I get the following error:

The 'inputs.parameters' of workflow operation 'Create_item' of type 'OpenApiConnection' is not valid. Error details: Input parameter 'item/ConversationCompletedDate' is required to be of type 'String/date'. The runtime value '""' to be converted doesn't have the expected format 'String/date'.

 

I'm not sure how to test for null date values.

 

nvpc_0-1620246775609.pngnvpc_1-1620246831312.png

I have now edited the create Item with the following code

nvpc_0-1620251365281.pngnvpc_1-1620251397879.png

which works! but I wanted to leave the date blank if it was null. I tried using Coalese but could not get that to work, that would give me the same answer.

So I tried the following and it worked;

nvpc_0-1620252265132.png

if(empty(items('Apply_to_each')?['Assigned Date']),null,formatdatetime(items('Apply_to_each')?['Assigned Date'],'MM/dd/yyyy'))

Thanks!

 

1 ACCEPTED SOLUTION

Accepted Solutions
Hardesh15
Super User
Super User

Accepting this thread as solution so that other can take help from this post.

Thanks @nvpc @deadmelgibson 

Please 'Thumbs Up' the posts that helped you and 'Accept as Solution' if my post answered your question.

@Hardesh /Gopenly.in

View solution in original post

2 REPLIES 2
deadmelgibson
Regular Visitor

nvpc... I don't know how to thank you. After hours of misery this has solved it for me.  God bless you good sir!

Hardesh15
Super User
Super User

Accepting this thread as solution so that other can take help from this post.

Thanks @nvpc @deadmelgibson 

Please 'Thumbs Up' the posts that helped you and 'Accept as Solution' if my post answered your question.

@Hardesh /Gopenly.in

Helpful resources

Announcements
October Events

Mark Your Calendars

So many events happening this month - don't miss out!

 WHAT’S NEXT AT MICROSOFT IGNITE 2022

WHAT’S NEXT AT MICROSOFT IGNITE 2022

Explore the latest innovations, learn from product experts and partners, level up your skillset, and create connections from around the world.

Register for a Free Workshop.png

Register for a Free Workshop

Learn to digitize and optimize business processes and connect all your applications to share data in real time.

Users online (3,482)