cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
SofticKabir
Helper III
Helper III

Different data in application and database?

Hello,

My "Table1" is a spreadsheet which is stored over OneDrive. I am also using Data Connection of OneDrive, so normally the data in the app should be the same as in the table. Somehow, the dates aren't the same, for example in the app I have 3 cases:

 

04.04.2021John Doe
01.03.2021Kabir Softic
01.03.2021Kabir Softic

 

These dates look different in my spreadsheet:

 

SofticKabir_0-1620748606261.png

 

Why are there different dates in the spreadsheet?

1 ACCEPTED SOLUTION

Accepted Solutions
v-albai-msft
Community Support
Community Support

Hi @SofticKabir ,

This is because your datasource and your app use different Time Zone.

You can manually offset the time. For example, assuming that:

1. You display Excel data inside a gallery. So the default formula for date filed is:

ThisItem.Datum

2. The time difference between your Excel and your app is 10 hours.

 

As a result, you can try this formula for the date field inside your galley:

DateAdd(ThisItem.Datum,10,Hours)

Or:

DateAdd(ThisItem.Datum,-10,Hours)

Note: Number 10 in above code is just an example, it means the difference hours. Remember to replace this number depending on your requirements. Also note the 

Best regards,

Allen

View solution in original post

2 REPLIES 2
v-albai-msft
Community Support
Community Support

Hi @SofticKabir ,

This is because your datasource and your app use different Time Zone.

You can manually offset the time. For example, assuming that:

1. You display Excel data inside a gallery. So the default formula for date filed is:

ThisItem.Datum

2. The time difference between your Excel and your app is 10 hours.

 

As a result, you can try this formula for the date field inside your galley:

DateAdd(ThisItem.Datum,10,Hours)

Or:

DateAdd(ThisItem.Datum,-10,Hours)

Note: Number 10 in above code is just an example, it means the difference hours. Remember to replace this number depending on your requirements. Also note the 

Best regards,

Allen

View solution in original post

Hello @v-albai-msft ,

thank you for the reply/hint.

I tried to apply the DateAdd() function for the Update property, and it kind of works.

For example when I choose the date "09/04/2021" and click on Submit, the date in Excel will be stored as such, but the problem is, with that, the date inside the app is always 1 day ahead, so "10/04/2021".

The solution was to just apply the same function for the app as well. Everywhere, where it would display the date +1 day, I would adjust it.

Thanks!

Best regards,

Softic Kabir

Helpful resources

Announcements
PA_User Group Leader_768x460.jpg

Manage your user group events

Check out the News & Announcements to learn more.

Power Query PA Forum 768x460.png

Check it out!

Did you know that you can visit the Power Query Forum in Power BI and now Power Apps

Carousel 2021 Release Wave 2 Plan 768x460.jpg

2021 Release Wave 2 Plan

Power Platform release plan for the 2021 release wave 2 describes all new features releasing from October 2021 through March 2022.

R2 (Green) 768 x 460px.png

Microsoft Dynamics 365 & Power Platform User Professionals

DynamicsCon is a FREE, 4 half-day virtual learning experience for 11,000+ Microsoft Business Application users and professionals.

Users online (2,779)