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

Community site session details

Session Id : dNzM6jNr/xYnwy0Nm9Dz3u
Power Automate - Using Flows
Unanswered

output days error

Like (0) ShareShare
ReportReport
Posted on 22 Oct 2021 01:11:13 by

hi i created the schedule flow its show the output is okay last night, but i receive today email, which when i check the output for the day remains constant where it should be add 1 day after yesterday.

norazimah_0-1634864862233.png 
this is my flow, in the days column i use this formula : 
div(sub(ticks(utcNow()), ticks(item()?['Created'])), 864000000000)

norazimah_1-1634864904445.png 

norazimah_2-1634864931486.png

 

 

 

I have the same question (0)
  • VJR Profile Picture
    7,635 on 22 Oct 2021 at 03:20:07
    Re: output days error

    HI @Anonymous 

     

    Make sure both the time zones you are comparing are the same.

    For eg you are using UtcNow in your function, but is the other date also in utc timezone?

    Remember there is always a gap of few hours between utc and the time zone you would be in.

     

    For eg; The current utc time as I write this post is 3:15 am 

    and time in IST timezone now is 8:45 am.

     

    The point is, the day(or date) may have changed in a "particular timezone" but it is still the previous day in utc, because of the gap in hours of this "particular timezone" and utc.

     

  • CFernandes Profile Picture
    8,396 Most Valuable Professional on 22 Oct 2021 at 04:34:05
    Re: output days error

    Hey @Anonymous 

     

    You will need to convert the timezone and then pass it to your "Select" action.

     

    To Convert the timezone you can use -

     

    CFernandes_1-1634877146306.png

    Formula --

     

    convertTimeZone(timestamp: string, sourceTimeZone: string, destinationTimeZone: string, format?: string)

     

    For details see - https://support.microsoft.com/en-us/topic/converting-time-zone-in-microsoft-power-automate-8bce2441-1859-4d76-2f51-985d9c96534d 

     

    If this reply has answered your question or solved your issue, please mark this question as answered. Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up. THANKS!

     

    P.S. take a look at my blog here and like & subscribe to my YouTube Channel thanks.

     

  • Community Power Platform Member Profile Picture
    on 22 Oct 2021 at 05:04:22
    Re: output days error

    data source is same as my time zone, example created date 13/10/2021 . so i need to change the time zone again? 

  • Community Power Platform Member Profile Picture
    on 22 Oct 2021 at 06:56:32
    Re: output days error

    its show an error after i put in the "select" action.
    i change the formula : 

    div(sub(ticks(body('Convert_time_zone'))), ticks(item()?['Created'])), 864000000000)
    norazimah_0-1634885648143.pngnorazimah_1-1634885673652.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

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Chiara Carbone – Community Spotlight

We are honored to recognize Chiara Carbone as our Community Spotlight for November…

Leaderboard > Power Automate

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 655 Super User 2025 Season 2

#2
Tomac Profile Picture

Tomac 371 Moderator

#3
chiaraalina Profile Picture

chiaraalina 276

Last 30 days Overall leaderboard

Featured topics

Restore a deleted flow
Loading complete