Why are both Nov 4 and Nov 5 2018 showing as Sunday?
Clash Royale CLAN TAG#URR8PPP
.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty margin-bottom:0;
up vote
1
down vote
favorite
I have a small piece of code which is displaying the Day of the week which is part of a larger method.
Date StartDate = Date.newInstance(2018, 11, 4);
Datetime StartDateDt = Datetime.newinstance(StartDate.year(),StartDate.month(),StartDate.day());
System.debug(StartDateDt);
System.debug(StartDateDt.format('EEEE') );
StartDateDt = StartDateDt.addDays(1);
System.debug(StartDateDt);
System.debug(StartDateDt.format('EEEE') );
If you look at the debug on the dev console
Any thoughts on what is happening here?
Update
if i was using GMT like what @Oleksandr Berehovskiy suggested then i get 4 nov as Saturday and 5 Nov as Sunday. Actually 4th is Sunday and 5th is a Monday
What i wanted was if i was running the code from the users locale then we should get the weekday from user's locale and not GMT
Interestingly the issue is only if the start date is given as 4th Nov. If i give the start date as 5 nov then it works fine
apex datetime
add a comment |Â
up vote
1
down vote
favorite
I have a small piece of code which is displaying the Day of the week which is part of a larger method.
Date StartDate = Date.newInstance(2018, 11, 4);
Datetime StartDateDt = Datetime.newinstance(StartDate.year(),StartDate.month(),StartDate.day());
System.debug(StartDateDt);
System.debug(StartDateDt.format('EEEE') );
StartDateDt = StartDateDt.addDays(1);
System.debug(StartDateDt);
System.debug(StartDateDt.format('EEEE') );
If you look at the debug on the dev console
Any thoughts on what is happening here?
Update
if i was using GMT like what @Oleksandr Berehovskiy suggested then i get 4 nov as Saturday and 5 Nov as Sunday. Actually 4th is Sunday and 5th is a Monday
What i wanted was if i was running the code from the users locale then we should get the weekday from user's locale and not GMT
Interestingly the issue is only if the start date is given as 4th Nov. If i give the start date as 5 nov then it works fine
apex datetime
add a comment |Â
up vote
1
down vote
favorite
up vote
1
down vote
favorite
I have a small piece of code which is displaying the Day of the week which is part of a larger method.
Date StartDate = Date.newInstance(2018, 11, 4);
Datetime StartDateDt = Datetime.newinstance(StartDate.year(),StartDate.month(),StartDate.day());
System.debug(StartDateDt);
System.debug(StartDateDt.format('EEEE') );
StartDateDt = StartDateDt.addDays(1);
System.debug(StartDateDt);
System.debug(StartDateDt.format('EEEE') );
If you look at the debug on the dev console
Any thoughts on what is happening here?
Update
if i was using GMT like what @Oleksandr Berehovskiy suggested then i get 4 nov as Saturday and 5 Nov as Sunday. Actually 4th is Sunday and 5th is a Monday
What i wanted was if i was running the code from the users locale then we should get the weekday from user's locale and not GMT
Interestingly the issue is only if the start date is given as 4th Nov. If i give the start date as 5 nov then it works fine
apex datetime
I have a small piece of code which is displaying the Day of the week which is part of a larger method.
Date StartDate = Date.newInstance(2018, 11, 4);
Datetime StartDateDt = Datetime.newinstance(StartDate.year(),StartDate.month(),StartDate.day());
System.debug(StartDateDt);
System.debug(StartDateDt.format('EEEE') );
StartDateDt = StartDateDt.addDays(1);
System.debug(StartDateDt);
System.debug(StartDateDt.format('EEEE') );
If you look at the debug on the dev console
Any thoughts on what is happening here?
Update
if i was using GMT like what @Oleksandr Berehovskiy suggested then i get 4 nov as Saturday and 5 Nov as Sunday. Actually 4th is Sunday and 5th is a Monday
What i wanted was if i was running the code from the users locale then we should get the weekday from user's locale and not GMT
Interestingly the issue is only if the start date is given as 4th Nov. If i give the start date as 5 nov then it works fine
apex datetime
apex datetime
edited 54 mins ago
asked 2 hours ago


Prady
6,4631885168
6,4631885168
add a comment |Â
add a comment |Â
1 Answer
1
active
oldest
votes
up vote
3
down vote
The reason of such behavior is daylight saving time offset.
You are doing everything okay. Result is expected with Datetime
class. Your user's timezone is America/Chicago
. According to Daylight Saving Time Changes 2018 article, 4-th of November was a day, when clock went back 1 hour.
Sunday, 4 November 2018, 02:00:00 clocks were turned backward 1 hour to
Sunday, 4 November 2018, 01:00:00 local standard time instead.
I have simplified your code to the following.
Datetime myDateTime = Datetime.newInstance(2018, 11, 4);
//DEBUG|myDateTime.format(yyyy-MM-dd HH:mm:ss):2018-11-04 00:00:00
System.debug('myDateTime.format(yyyy-MM-dd HH:mm:ss):' + myDateTime.format('yyyy-MM-dd HH:mm:ss'));
//DEBUG|myDateTime.formatGMT(yyyy-MM-dd HH:mm:ss):2018-11-04 05:00:00
System.debug('myDateTime.formatGMT(yyyy-MM-dd HH:mm:ss):' + myDateTime.formatGMT('yyyy-MM-dd HH:mm:ss'));
Datetime newDateTime = myDateTime.addDays(1);
//DEBUG|newDateTime.format(yyyy-MM-dd HH:mm:ss):2018-11-04 23:00:00
System.debug('newDateTime.format(yyyy-MM-dd HH:mm:ss):' + newDateTime.format('yyyy-MM-dd HH:mm:ss'));
//|DEBUG|newDateTime.formatGMT(yyyy-MM-dd HH:mm:ss):2018-11-05 05:00:00
System.debug('newDateTime.formatGMT(yyyy-MM-dd HH:mm:ss):' + newDateTime.formatGMT('yyyy-MM-dd HH:mm:ss'));
Datetime myDateTime = Datetime.newInstance(2018, 11, 4);
here you constructing local Chicago time 4-th of November 00:00:00
after 2 hours, it is 02:00:00
and immediately time goes back 1 hour and it becomes 01:00:00
time. So you have not 24 hours per day, but 25.
And looks like Datetime.addDays
method adds 24 hours to Datetime and that is why after myDateTime.addDays(1)
you have 2018-11-04 23:00:00
. If you add 25 hours to it, you will get expected 2018-11-05 00:00:00
and Monday
result.
What final conclusion I did from current case.
If you don't have to work with/get/manipulate with hours, minutes and seconds - always use Date class. Because it adds days correctly with all daylight saving time offsets.
Date myDate = Date.newInstance(2018, 11, 4);
//DEBUG|myDate.format(yyyy-MM-dd):11/4/2018
System.debug('myDate.format(yyyy-MM-dd):' + myDate.format());
Date newMyDate = myDate.addDays(1);
//DEBUG|newMyDate.format:11/5/2018
System.debug('newMyDate.format:' + newMyDate.format());
DateTime newMyDateTime = DateTime.newInstance(newMyDate.year(), newMyDate.month(), newMyDate.day());
//newMyDateTime.format(yyyy-MM-dd HH:mm:ss):2018-11-05 00:00:00
System.debug('newMyDateTime.format(yyyy-MM-dd HH:mm:ss):' + newMyDateTime.format('yyyy-MM-dd HH:mm:ss'));
//DEBUG|newMyDateTime.format(EEEE):Monday
System.debug('newMyDateTime.format(EEEE):' + newMyDateTime.format('EEEE'));
from upper snippet, we convert Date
to Datetime
at the latest step, where we need to know what is a day of the week. But all manipulations we did with Date
class
I specifically wanted to create on users timezone because when i run the code using GMT i get 4 nov as Saturday and 5 Nov as Sunday. Actually 4th is Sunday and 5th is a Monday
– Prady
2 hours ago
@Prady what timezone do you have on your user?
– Oleksandr Berehovskiy
2 hours ago
(GMT-06:00) Central Standard Time (America/Chicago)
– Prady
2 hours ago
@Prady I have updated my answer.
– Oleksandr Berehovskiy
23 mins ago
add a comment |Â
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
up vote
3
down vote
The reason of such behavior is daylight saving time offset.
You are doing everything okay. Result is expected with Datetime
class. Your user's timezone is America/Chicago
. According to Daylight Saving Time Changes 2018 article, 4-th of November was a day, when clock went back 1 hour.
Sunday, 4 November 2018, 02:00:00 clocks were turned backward 1 hour to
Sunday, 4 November 2018, 01:00:00 local standard time instead.
I have simplified your code to the following.
Datetime myDateTime = Datetime.newInstance(2018, 11, 4);
//DEBUG|myDateTime.format(yyyy-MM-dd HH:mm:ss):2018-11-04 00:00:00
System.debug('myDateTime.format(yyyy-MM-dd HH:mm:ss):' + myDateTime.format('yyyy-MM-dd HH:mm:ss'));
//DEBUG|myDateTime.formatGMT(yyyy-MM-dd HH:mm:ss):2018-11-04 05:00:00
System.debug('myDateTime.formatGMT(yyyy-MM-dd HH:mm:ss):' + myDateTime.formatGMT('yyyy-MM-dd HH:mm:ss'));
Datetime newDateTime = myDateTime.addDays(1);
//DEBUG|newDateTime.format(yyyy-MM-dd HH:mm:ss):2018-11-04 23:00:00
System.debug('newDateTime.format(yyyy-MM-dd HH:mm:ss):' + newDateTime.format('yyyy-MM-dd HH:mm:ss'));
//|DEBUG|newDateTime.formatGMT(yyyy-MM-dd HH:mm:ss):2018-11-05 05:00:00
System.debug('newDateTime.formatGMT(yyyy-MM-dd HH:mm:ss):' + newDateTime.formatGMT('yyyy-MM-dd HH:mm:ss'));
Datetime myDateTime = Datetime.newInstance(2018, 11, 4);
here you constructing local Chicago time 4-th of November 00:00:00
after 2 hours, it is 02:00:00
and immediately time goes back 1 hour and it becomes 01:00:00
time. So you have not 24 hours per day, but 25.
And looks like Datetime.addDays
method adds 24 hours to Datetime and that is why after myDateTime.addDays(1)
you have 2018-11-04 23:00:00
. If you add 25 hours to it, you will get expected 2018-11-05 00:00:00
and Monday
result.
What final conclusion I did from current case.
If you don't have to work with/get/manipulate with hours, minutes and seconds - always use Date class. Because it adds days correctly with all daylight saving time offsets.
Date myDate = Date.newInstance(2018, 11, 4);
//DEBUG|myDate.format(yyyy-MM-dd):11/4/2018
System.debug('myDate.format(yyyy-MM-dd):' + myDate.format());
Date newMyDate = myDate.addDays(1);
//DEBUG|newMyDate.format:11/5/2018
System.debug('newMyDate.format:' + newMyDate.format());
DateTime newMyDateTime = DateTime.newInstance(newMyDate.year(), newMyDate.month(), newMyDate.day());
//newMyDateTime.format(yyyy-MM-dd HH:mm:ss):2018-11-05 00:00:00
System.debug('newMyDateTime.format(yyyy-MM-dd HH:mm:ss):' + newMyDateTime.format('yyyy-MM-dd HH:mm:ss'));
//DEBUG|newMyDateTime.format(EEEE):Monday
System.debug('newMyDateTime.format(EEEE):' + newMyDateTime.format('EEEE'));
from upper snippet, we convert Date
to Datetime
at the latest step, where we need to know what is a day of the week. But all manipulations we did with Date
class
I specifically wanted to create on users timezone because when i run the code using GMT i get 4 nov as Saturday and 5 Nov as Sunday. Actually 4th is Sunday and 5th is a Monday
– Prady
2 hours ago
@Prady what timezone do you have on your user?
– Oleksandr Berehovskiy
2 hours ago
(GMT-06:00) Central Standard Time (America/Chicago)
– Prady
2 hours ago
@Prady I have updated my answer.
– Oleksandr Berehovskiy
23 mins ago
add a comment |Â
up vote
3
down vote
The reason of such behavior is daylight saving time offset.
You are doing everything okay. Result is expected with Datetime
class. Your user's timezone is America/Chicago
. According to Daylight Saving Time Changes 2018 article, 4-th of November was a day, when clock went back 1 hour.
Sunday, 4 November 2018, 02:00:00 clocks were turned backward 1 hour to
Sunday, 4 November 2018, 01:00:00 local standard time instead.
I have simplified your code to the following.
Datetime myDateTime = Datetime.newInstance(2018, 11, 4);
//DEBUG|myDateTime.format(yyyy-MM-dd HH:mm:ss):2018-11-04 00:00:00
System.debug('myDateTime.format(yyyy-MM-dd HH:mm:ss):' + myDateTime.format('yyyy-MM-dd HH:mm:ss'));
//DEBUG|myDateTime.formatGMT(yyyy-MM-dd HH:mm:ss):2018-11-04 05:00:00
System.debug('myDateTime.formatGMT(yyyy-MM-dd HH:mm:ss):' + myDateTime.formatGMT('yyyy-MM-dd HH:mm:ss'));
Datetime newDateTime = myDateTime.addDays(1);
//DEBUG|newDateTime.format(yyyy-MM-dd HH:mm:ss):2018-11-04 23:00:00
System.debug('newDateTime.format(yyyy-MM-dd HH:mm:ss):' + newDateTime.format('yyyy-MM-dd HH:mm:ss'));
//|DEBUG|newDateTime.formatGMT(yyyy-MM-dd HH:mm:ss):2018-11-05 05:00:00
System.debug('newDateTime.formatGMT(yyyy-MM-dd HH:mm:ss):' + newDateTime.formatGMT('yyyy-MM-dd HH:mm:ss'));
Datetime myDateTime = Datetime.newInstance(2018, 11, 4);
here you constructing local Chicago time 4-th of November 00:00:00
after 2 hours, it is 02:00:00
and immediately time goes back 1 hour and it becomes 01:00:00
time. So you have not 24 hours per day, but 25.
And looks like Datetime.addDays
method adds 24 hours to Datetime and that is why after myDateTime.addDays(1)
you have 2018-11-04 23:00:00
. If you add 25 hours to it, you will get expected 2018-11-05 00:00:00
and Monday
result.
What final conclusion I did from current case.
If you don't have to work with/get/manipulate with hours, minutes and seconds - always use Date class. Because it adds days correctly with all daylight saving time offsets.
Date myDate = Date.newInstance(2018, 11, 4);
//DEBUG|myDate.format(yyyy-MM-dd):11/4/2018
System.debug('myDate.format(yyyy-MM-dd):' + myDate.format());
Date newMyDate = myDate.addDays(1);
//DEBUG|newMyDate.format:11/5/2018
System.debug('newMyDate.format:' + newMyDate.format());
DateTime newMyDateTime = DateTime.newInstance(newMyDate.year(), newMyDate.month(), newMyDate.day());
//newMyDateTime.format(yyyy-MM-dd HH:mm:ss):2018-11-05 00:00:00
System.debug('newMyDateTime.format(yyyy-MM-dd HH:mm:ss):' + newMyDateTime.format('yyyy-MM-dd HH:mm:ss'));
//DEBUG|newMyDateTime.format(EEEE):Monday
System.debug('newMyDateTime.format(EEEE):' + newMyDateTime.format('EEEE'));
from upper snippet, we convert Date
to Datetime
at the latest step, where we need to know what is a day of the week. But all manipulations we did with Date
class
I specifically wanted to create on users timezone because when i run the code using GMT i get 4 nov as Saturday and 5 Nov as Sunday. Actually 4th is Sunday and 5th is a Monday
– Prady
2 hours ago
@Prady what timezone do you have on your user?
– Oleksandr Berehovskiy
2 hours ago
(GMT-06:00) Central Standard Time (America/Chicago)
– Prady
2 hours ago
@Prady I have updated my answer.
– Oleksandr Berehovskiy
23 mins ago
add a comment |Â
up vote
3
down vote
up vote
3
down vote
The reason of such behavior is daylight saving time offset.
You are doing everything okay. Result is expected with Datetime
class. Your user's timezone is America/Chicago
. According to Daylight Saving Time Changes 2018 article, 4-th of November was a day, when clock went back 1 hour.
Sunday, 4 November 2018, 02:00:00 clocks were turned backward 1 hour to
Sunday, 4 November 2018, 01:00:00 local standard time instead.
I have simplified your code to the following.
Datetime myDateTime = Datetime.newInstance(2018, 11, 4);
//DEBUG|myDateTime.format(yyyy-MM-dd HH:mm:ss):2018-11-04 00:00:00
System.debug('myDateTime.format(yyyy-MM-dd HH:mm:ss):' + myDateTime.format('yyyy-MM-dd HH:mm:ss'));
//DEBUG|myDateTime.formatGMT(yyyy-MM-dd HH:mm:ss):2018-11-04 05:00:00
System.debug('myDateTime.formatGMT(yyyy-MM-dd HH:mm:ss):' + myDateTime.formatGMT('yyyy-MM-dd HH:mm:ss'));
Datetime newDateTime = myDateTime.addDays(1);
//DEBUG|newDateTime.format(yyyy-MM-dd HH:mm:ss):2018-11-04 23:00:00
System.debug('newDateTime.format(yyyy-MM-dd HH:mm:ss):' + newDateTime.format('yyyy-MM-dd HH:mm:ss'));
//|DEBUG|newDateTime.formatGMT(yyyy-MM-dd HH:mm:ss):2018-11-05 05:00:00
System.debug('newDateTime.formatGMT(yyyy-MM-dd HH:mm:ss):' + newDateTime.formatGMT('yyyy-MM-dd HH:mm:ss'));
Datetime myDateTime = Datetime.newInstance(2018, 11, 4);
here you constructing local Chicago time 4-th of November 00:00:00
after 2 hours, it is 02:00:00
and immediately time goes back 1 hour and it becomes 01:00:00
time. So you have not 24 hours per day, but 25.
And looks like Datetime.addDays
method adds 24 hours to Datetime and that is why after myDateTime.addDays(1)
you have 2018-11-04 23:00:00
. If you add 25 hours to it, you will get expected 2018-11-05 00:00:00
and Monday
result.
What final conclusion I did from current case.
If you don't have to work with/get/manipulate with hours, minutes and seconds - always use Date class. Because it adds days correctly with all daylight saving time offsets.
Date myDate = Date.newInstance(2018, 11, 4);
//DEBUG|myDate.format(yyyy-MM-dd):11/4/2018
System.debug('myDate.format(yyyy-MM-dd):' + myDate.format());
Date newMyDate = myDate.addDays(1);
//DEBUG|newMyDate.format:11/5/2018
System.debug('newMyDate.format:' + newMyDate.format());
DateTime newMyDateTime = DateTime.newInstance(newMyDate.year(), newMyDate.month(), newMyDate.day());
//newMyDateTime.format(yyyy-MM-dd HH:mm:ss):2018-11-05 00:00:00
System.debug('newMyDateTime.format(yyyy-MM-dd HH:mm:ss):' + newMyDateTime.format('yyyy-MM-dd HH:mm:ss'));
//DEBUG|newMyDateTime.format(EEEE):Monday
System.debug('newMyDateTime.format(EEEE):' + newMyDateTime.format('EEEE'));
from upper snippet, we convert Date
to Datetime
at the latest step, where we need to know what is a day of the week. But all manipulations we did with Date
class
The reason of such behavior is daylight saving time offset.
You are doing everything okay. Result is expected with Datetime
class. Your user's timezone is America/Chicago
. According to Daylight Saving Time Changes 2018 article, 4-th of November was a day, when clock went back 1 hour.
Sunday, 4 November 2018, 02:00:00 clocks were turned backward 1 hour to
Sunday, 4 November 2018, 01:00:00 local standard time instead.
I have simplified your code to the following.
Datetime myDateTime = Datetime.newInstance(2018, 11, 4);
//DEBUG|myDateTime.format(yyyy-MM-dd HH:mm:ss):2018-11-04 00:00:00
System.debug('myDateTime.format(yyyy-MM-dd HH:mm:ss):' + myDateTime.format('yyyy-MM-dd HH:mm:ss'));
//DEBUG|myDateTime.formatGMT(yyyy-MM-dd HH:mm:ss):2018-11-04 05:00:00
System.debug('myDateTime.formatGMT(yyyy-MM-dd HH:mm:ss):' + myDateTime.formatGMT('yyyy-MM-dd HH:mm:ss'));
Datetime newDateTime = myDateTime.addDays(1);
//DEBUG|newDateTime.format(yyyy-MM-dd HH:mm:ss):2018-11-04 23:00:00
System.debug('newDateTime.format(yyyy-MM-dd HH:mm:ss):' + newDateTime.format('yyyy-MM-dd HH:mm:ss'));
//|DEBUG|newDateTime.formatGMT(yyyy-MM-dd HH:mm:ss):2018-11-05 05:00:00
System.debug('newDateTime.formatGMT(yyyy-MM-dd HH:mm:ss):' + newDateTime.formatGMT('yyyy-MM-dd HH:mm:ss'));
Datetime myDateTime = Datetime.newInstance(2018, 11, 4);
here you constructing local Chicago time 4-th of November 00:00:00
after 2 hours, it is 02:00:00
and immediately time goes back 1 hour and it becomes 01:00:00
time. So you have not 24 hours per day, but 25.
And looks like Datetime.addDays
method adds 24 hours to Datetime and that is why after myDateTime.addDays(1)
you have 2018-11-04 23:00:00
. If you add 25 hours to it, you will get expected 2018-11-05 00:00:00
and Monday
result.
What final conclusion I did from current case.
If you don't have to work with/get/manipulate with hours, minutes and seconds - always use Date class. Because it adds days correctly with all daylight saving time offsets.
Date myDate = Date.newInstance(2018, 11, 4);
//DEBUG|myDate.format(yyyy-MM-dd):11/4/2018
System.debug('myDate.format(yyyy-MM-dd):' + myDate.format());
Date newMyDate = myDate.addDays(1);
//DEBUG|newMyDate.format:11/5/2018
System.debug('newMyDate.format:' + newMyDate.format());
DateTime newMyDateTime = DateTime.newInstance(newMyDate.year(), newMyDate.month(), newMyDate.day());
//newMyDateTime.format(yyyy-MM-dd HH:mm:ss):2018-11-05 00:00:00
System.debug('newMyDateTime.format(yyyy-MM-dd HH:mm:ss):' + newMyDateTime.format('yyyy-MM-dd HH:mm:ss'));
//DEBUG|newMyDateTime.format(EEEE):Monday
System.debug('newMyDateTime.format(EEEE):' + newMyDateTime.format('EEEE'));
from upper snippet, we convert Date
to Datetime
at the latest step, where we need to know what is a day of the week. But all manipulations we did with Date
class
edited 11 mins ago
answered 2 hours ago


Oleksandr Berehovskiy
8,36021835
8,36021835
I specifically wanted to create on users timezone because when i run the code using GMT i get 4 nov as Saturday and 5 Nov as Sunday. Actually 4th is Sunday and 5th is a Monday
– Prady
2 hours ago
@Prady what timezone do you have on your user?
– Oleksandr Berehovskiy
2 hours ago
(GMT-06:00) Central Standard Time (America/Chicago)
– Prady
2 hours ago
@Prady I have updated my answer.
– Oleksandr Berehovskiy
23 mins ago
add a comment |Â
I specifically wanted to create on users timezone because when i run the code using GMT i get 4 nov as Saturday and 5 Nov as Sunday. Actually 4th is Sunday and 5th is a Monday
– Prady
2 hours ago
@Prady what timezone do you have on your user?
– Oleksandr Berehovskiy
2 hours ago
(GMT-06:00) Central Standard Time (America/Chicago)
– Prady
2 hours ago
@Prady I have updated my answer.
– Oleksandr Berehovskiy
23 mins ago
I specifically wanted to create on users timezone because when i run the code using GMT i get 4 nov as Saturday and 5 Nov as Sunday. Actually 4th is Sunday and 5th is a Monday
– Prady
2 hours ago
I specifically wanted to create on users timezone because when i run the code using GMT i get 4 nov as Saturday and 5 Nov as Sunday. Actually 4th is Sunday and 5th is a Monday
– Prady
2 hours ago
@Prady what timezone do you have on your user?
– Oleksandr Berehovskiy
2 hours ago
@Prady what timezone do you have on your user?
– Oleksandr Berehovskiy
2 hours ago
(GMT-06:00) Central Standard Time (America/Chicago)
– Prady
2 hours ago
(GMT-06:00) Central Standard Time (America/Chicago)
– Prady
2 hours ago
@Prady I have updated my answer.
– Oleksandr Berehovskiy
23 mins ago
@Prady I have updated my answer.
– Oleksandr Berehovskiy
23 mins ago
add a comment |Â
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fsalesforce.stackexchange.com%2fquestions%2f238465%2fwhy-are-both-nov-4-and-nov-5-2018-showing-as-sunday%23new-answer', 'question_page');
);
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password