Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Time zone may not be correct #18484

Closed
mkassir95 opened this issue Dec 10, 2021 · 11 comments
Closed

Time zone may not be correct #18484

mkassir95 opened this issue Dec 10, 2021 · 11 comments
Labels
answered For when a question was asked and we referred to forum or answered it.

Comments

@mkassir95
Copy link

mkassir95 commented Dec 10, 2021

I am using matomo latest version 4.6.2 .
I feel that that the time zone is not accurate , it is behind the real time zone by two hours (please look at my PC clock)
image

@mkassir95 mkassir95 added the Potential Bug Something that might be a bug, but needs validation and confirmation it can be reproduced. label Dec 10, 2021
@sgiehl
Copy link
Member

sgiehl commented Dec 10, 2021

Hi @mkassir95. As the text says, the displayed time is UTC. So guess you are having a timezone with UTC+2?

@mkassir95
Copy link
Author

mkassir95 commented Dec 10, 2021

yes lebanon timezone is UTC+2
image
How can I adjust this ?

@sgiehl
Copy link
Member

sgiehl commented Dec 10, 2021

You do not need to adjust anything. If you select your timezone in the drop down, this timezone will be used for newly created websites. The time displayed in the description is for informal purpose only and will always display the UTC time.

@mkassir95
Copy link
Author

mkassir95 commented Dec 10, 2021

but the server time saved in the database is UTC and not the select zone time , in the dashboard the time is correct UTC+2 but in the database the time is UTC

@mkassir95
Copy link
Author

image
image

@mkassir95
Copy link
Author

The database is UTC while the dashboard is UTC+2

@sgiehl
Copy link
Member

sgiehl commented Dec 10, 2021

Yes. The database is always using UTC. The dashboard should use the timezone that is configured for the site.

@mkassir95
Copy link
Author

mkassir95 commented Dec 10, 2021

Then , is there a solution for this in order to read the real time form the database without workaround?

@sgiehl
Copy link
Member

sgiehl commented Dec 10, 2021

I think I don't understand your problem. If you want your data being processed in UTC, simply select UTC as timezone for the website.

@mkassir95
Copy link
Author

mkassir95 commented Dec 10, 2021

I need to generate custom reports and I do not want use the reports generated by the dashboard . So , I will fetch the data from the database to generate my custom reports and I will not use the dashboard . For this I will be facing a problem because the UTC is used as a timezone in the database even though I selected my local timezone

@sgiehl
Copy link
Member

sgiehl commented Dec 13, 2021

UTC is used in that database for a very good reason and this won't be changed. If you want to generate reports using database data directly, you need to adjust the returned datetime values on your own. All reports returned by the UI or the API should do that automatically for you.

@sgiehl sgiehl closed this as completed Dec 13, 2021
@sgiehl sgiehl added answered For when a question was asked and we referred to forum or answered it. and removed Potential Bug Something that might be a bug, but needs validation and confirmation it can be reproduced. labels Dec 13, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
answered For when a question was asked and we referred to forum or answered it.
Projects
None yet
Development

No branches or pull requests

2 participants