web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / Replace Excel Date Num...
Power Automate
Answered

Replace Excel Date Number in a Select Map using If expression

(0) ShareShare
ReportReport
Posted on by 39
I list rows from an Excel Spreadsheet that contain  two Columns, one is a title the other a value.   One of the rows contains a date.   The date arrives as a number from 1/1/1900 that has to be composed into a date.  This date is stored in a variable.    I would like to run a select that maps Colum1 to Loan, and  Colum2 to Value.   Unless colum2 contains the the Excel formatted number.  In this case I like to use the date variable that was created earlier in the flow.   Below is the formula I am using, however the output  for  the if expression is "".    What is wrong with my expression?
 
 Riskyplan_1-1699224709450.png

 

If(equals(outputs('List_rows_present_in_a_table_2')?['body/value'][0]?['Column1'],'Last Payment Date'),outputs('Compose_Last_payment_date'),outputs('List_rows_present_in_a_table_2')?['body/value'][0]['Column2'])
 
This is the out put when the flow runs.  
Riskyplan_0-1699224664799.pngRiskyplan_2-1699224852717.png

 

Categories:
I have the same question (0)
  • Verified answer
    grantjenkins Profile Picture
    11,063 Moderator on at

    When you retrieve your Excel data you can set DateTime Format to ISO 8601 so your dates come back as normal dates (not serial dates) and won't need to be converted.

     

    grantjenkins_0-1699226488920.png

  • Riskyplan Profile Picture
    39 on at

    Thanks for the reply and solution that I was unaware of.   Is there anything preventing the date from pulling in as ISO 8601.   I still seem to be only pulling in the serial number format.  

    Riskyplan_0-1699291538114.pngRiskyplan_1-1699291602395.png

     

  • Riskyplan Profile Picture
    39 on at

    Since I am using a named formula to create the date in the excel table I do not believe ISO 8601 setting will covert the serial number.    I still am getting the serial number under list rows present in a table.   

     

    The original questions stands.  basically how can I create an HTML table that has the excel table data organized in two columns replacing the serial date with a an actual date?

  • Verified answer
    Riskyplan Profile Picture
    39 on at

    Found the solution:   Changed the formula used in the Select step to:

    If(equals(Item()?['Column1'],'Last Payment Date'),outputs('Compose_Last_payment_date'),item()?['Column2'])

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

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Automate

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 501 Super User 2025 Season 2

#2
Tomac Profile Picture

Tomac 323 Moderator

#3
abm abm Profile Picture

abm abm 237 Most Valuable Professional

Last 30 days Overall leaderboard