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 / Insert row into SQL fl...
Power Automate
Unanswered

Insert row into SQL flow saves dates minus one day

(0) ShareShare
ReportReport
Posted on by 6

I built a flow to take data from an excel file and insert it into a SQL table. However, when I check the data saved into the SQL table all the dates are minus one day. 

medellsi24_0-1652977868320.pngmedellsi24_1-1652977874628.png

Following is the comparison between excel and the SQL table. 

medellsi24_2-1652977913102.png

medellsi24_3-1652977922287.png

Does anyone have a suggestion on how to address this or if it could be caused by the insertion into SQL itself?

 

Thanks

 

Categories:
I have the same question (0)
  • Verified answer
    Heartholme Profile Picture
    1,278 Super User 2024 Season 1 on at

    Hi @medellsi24 

     

     

    The issue is that if you set the default date as a text value with no time component and time zone set to UTC (the 'Z' at the end), it will convert to a Date value, and the date will be converted to a date in the local time zone. If you are anywhere west of UTC (i.e., almost all of the Western hemisphere, incluinding the Americas), then it will end up in the day before. 

     

    Could you add a compose to extract out the date and we can look into reformat it to not jump a day. 


    Best Regards
    Heartholme

  • medellsi24 Profile Picture
    6 on at

    Thanks for that information, I was able to work around this by using formatDateTime to only pass on the date without a time zone for example: formatDateTime(ITEM()?['QTRBEG'], 'MM-dd-yyy').

  • Heartholme Profile Picture
    1,278 Super User 2024 Season 1 on at

    Perfect 🙂 Glad to hear!

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 525 Super User 2025 Season 2

#2
Tomac Profile Picture

Tomac 425 Moderator

#3
abm abm Profile Picture

abm abm 245 Most Valuable Professional

Last 30 days Overall leaderboard