Skip to main content
Community site session details

Community site session details

Session Id : CBFy4UMXMg6k8mF8kyXdCX
Power Automate - General Discussion
Answered

Need help to fix date issue

Like (0) ShareShare
ReportReport
Posted on 23 Jul 2023 20:37:12 by

I have excel data and it has the date column of created.

Its in power automate.I'm using excel as connector. I used the formula for adddays('1899/12/30',int(item()?['Created']),'yyyy/MM/dd') is not working it says the template language int is invoked.value cannot be converted as target type.

I used the other formula for 

div
(
sub
(
ticks(formatDateTime(item()?['Created'], 'yyyy-MM-ddT00:00:00')),
599264352000000000),
864000000000
)
It says its not in iso format.
Kindly let me know how to go about this.
Thanks.
  • Verified answer
    SudeepGhatakNZ Profile Picture
    14,381 Most Valuable Professional on 26 Jul 2023 at 21:39:47
    Re: Need help to fix date issue

    Please format the column with the Date option. I think it is currently set to General

    SudeepGhatakNZ_0-1690407579807.png

     

    Why is Excel Changing Dates to Random Numbers? | Date Changes to 5 Digit Number - YouTube

  • Priyanka03 Profile Picture
    on 26 Jul 2023 at 10:22:31
    Re: Need help to fix date issue

    I put the same in iso format in list rows but all of my date column is changed into iso format except one column is like 45096 this format. so if i'm trying to formatdatetime(item()?['Accepted'],'MM/dd/yyy')

    it throws an error string doesn't match the iso format. 

     

    Could you please tell me how to overcome this?

  • SudeepGhatakNZ Profile Picture
    14,381 Most Valuable Professional on 25 Jul 2023 at 23:41:33
    Re: Need help to fix date issue

    If you add item()?['Created'] in a compose message what does it print?

     

     

  • Priyanka03 Profile Picture
    on 24 Jul 2023 at 15:20:14
    Re: Need help to fix date issue

    @SudeepGhatakNZ ,

    I need to filter the older 60 days of record (created Column) from current date. 

    Later i need to check the date difference between created to completed .

    If i put that option in list rows then i'm trying to format the date as formatdatetime(item()?['Created'],'MM/dd/yyyy') it throws an error that is not iso format.

  • SudeepGhatakNZ Profile Picture
    14,381 Most Valuable Professional on 23 Jul 2023 at 23:05:12
    Re: Need help to fix date issue

    @Priyanka03 ,

    When querying data from excel, set the Date time format to ISO 8601.

    What is your logic behind adding days?

    SudeepGhatakNZ_0-1690153443514.png

     

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

Announcing our 2025 Season 2 Super Users!

A new season of Super Users has arrived, and we are so grateful for…

Paul Stork – Community Spotlight

We are honored to recognize Paul Stork as our July 2025 Community…

Congratulations to the June Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Automate

#1
Tomac Profile Picture

Tomac 986 Moderator

#2
stampcoin Profile Picture

stampcoin 699 Super User 2025 Season 2

#3
Riyaz_riz11 Profile Picture

Riyaz_riz11 577 Super User 2025 Season 2