1st Jan 2022 grouped as week 0

Hi there, I have a question that displays data for past 2 weeks (in this scenario 19th Jan 21 - 1 Jan 22). It worked perfectly in the past but recently it has started to group one day which is 1st Jan 2022 as Week 0. The rest of the days are grouped correctly as week 51 and 52.

Note: Under localization settings, first day of the week is set as Sunday.

My diagnostics

"browser-info": {
"language": "en-US",
"platform": "Win32",
"userAgent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/96.0.4664.110 Safari/537.36 Edg/96.0.1054.62",
"vendor": "Google Inc."
"system-info": {
"file.encoding": "UTF-8",
"java.runtime.name": "OpenJDK Runtime Environment",
"java.runtime.version": "11.0.12+7",
"java.vendor": "Eclipse Foundation",
"java.vendor.url": "https://adoptium.net/",
"java.version": "11.0.12",
"java.vm.name": "OpenJDK 64-Bit Server VM",
"java.vm.version": "11.0.12+7",
"os.name": "Linux",
"os.version": "4.15.0-1065-aws",
"user.language": "en",
"user.timezone": "Asia/Riyadh"
"metabase-info": {
"databases": [
"hosting-env": "unknown",
"application-database": "postgres",
"application-database-details": {
"database": {
"name": "PostgreSQL",
"version": "12.7"
"jdbc-driver": {
"name": "PostgreSQL JDBC Driver",
"version": "42.2.23"
"run-mode": "prod",
"version": {
"date": "2021-10-21",
"tag": "v0.41.1",
"branch": "release-x.41.x",
"hash": "76aa4a5"
"settings": {
"report-timezone": "Asia/Kuwait"

Hi @shahmirali
You should upgrade immediately to latest release: https://github.com/metabase/metabase/releases/latest
Which version of MongoDB?
Does this also happen on regular table (not pivoted)?

MongoDB version: 4.2.3
Its happening to all questions written in native query.

@shahmirali If it only happens to questions written in Native, then it sounds like the problem comes from what you are returning vs when you create the question in GUI.