I'm trying to write a code that visits in another website
The other page uses some sort of logic for the dates, for example:
634655520000000000 - 23/2/2012 - Feb 23, 2012
634649472000000000 - 16/2/2012 - Feb 16, 2012
634641696000000000 - 7/2/2012 - Feb 7, 2012
634631328000000000 - 26/1/2012 - Jan 26, 2012
http://www.tase.co.il/TASE/Statistics/ShortSale/ShortSaleData/ShortSalesWeekly.htm?action=1&issubmitted=1&dt=634679712000000000&dateLinksID=3
is the mar 22, 2012
can someone figure out a connection between the dates and this var?
That is the time starting from 1.1.1601 in steps of 100 nano seconds.
Related
We have a linux system that we are building with yocto.
We can read our hardware clock after reboots, change both system time and hardware time without any error (most of the time). However; after some new month, every year that we have tried we are running in to this error. "hwclock: RTC_RD_TIME: Invalid argument".
Example 1:
root#:~# date
Thu Apr 30 23:59:50 UTC 2020
root#:~# hwclock
Thu Apr 30 23:59:52 2020 0.000000 seconds
root#:~#
root#:~#
root#:~# date
Fri May 1 00:00:10 UTC 2020
root#:~# hwclock
hwclock: RTC_TD_TIME: Invalid argument
root#:~#
This is not happening every new month, if I do the same test in January linux can read the hwclock without any issues. It does also not matter if the unit is powered or not. If I set the hwclock to first of May 00:00:00 it can keep track of the time.
The same error occurs on the following month shift:
Feb (it does not matter if it is leap year or not) -> Mar
Apr -> May
Jun -> Jul
Sep -> Oct
Nov -> Dec
Dec (Not sure because of new year or new month) -> Jan
In my understanding, this is happening because rtc-lib.c cannot verify the time correctly.
I have tried on multiple different hardware
Does anyone have any idea what might cause this?
Solution:
The fault was not in rtc-lib.c. The cause of the error was a faulty RTC implementation. The RTC month value is 1-indexed, but the kernel assumes it is 0-indexed. Added a patch for this to rtc-[my_rtc_model].c and now it seems to be working.
Postgresql is rather good at handling timezones, using the classic tzdata database.
The server can convert past and future timestamps between the different timezones, following the rules in tzdata (offsets, dst changes, ..)
Is there a simple and efficient way, for a given timezone and a given date range, to extract all the timestamps within that range when a timezone modification event occured ?
the result should more or less contain the equivalent of the output of the zdump linux command.
zdump -v /usr/share/zoneinfo/America/Los_Angeles | grep 2017
Sun Mar 12 09:59:59 2017 UTC = Sun Mar 12 01:59:59 2017 PST isdst=0 gmtoff=-28800
Sun Mar 12 10:00:00 2017 UTC = Sun Mar 12 03:00:00 2017 PDT isdst=1 gmtoff=-25200
Sun Nov 5 08:59:59 2017 UTC = Sun Nov 5 01:59:59 2017 PDT isdst=1 gmtoff=-25200
Sun Nov 5 09:00:00 2017 UTC = Sun Nov 5 01:00:00 2017 PST isdst=0 gmtoff=-28800
select d::date
from (
select
d at time zone 'America/Los_Angeles' as la,
lead(d at time zone 'America/Los_Angeles') over (order by d) as la_,
d
from generate_series (
'2017-01-01'::timestamp,
'2017-12-31', '1 day'
) gs (d)
) s
where la::time <> la_::time;
d
------------
2017-03-12
2017-11-05
I have time strings of the following format
November 05, 2016, 01:02:31 PM
Does any one know how can I parse them into golang Time?
https://golang.org/pkg/time/#Parse
time.Parse(`January 02, 2006, 15:04:05 PM`, `November 05, 2016, 01:02:31 PM`)
https://play.golang.org/p/LOD5D-8i_U
I have a Google spreadsheet with columns I and J with data as headers Est Closing Month and Est Closing Calendar Year respectively, I need a script which will loop through columns I and J and find dates which are in the past month of this year and highlight them in Red.
Following is example data
ColI ColJ
Aug 2014
Nov 2014
Aug 2014
Jul 2014
Jul 2014
Dec 2014
Dec 2014
After I run the script the output put should be
Aug 2014
Nov 2014
Aug 2014
Jul 2014 -> Both Cells should be in red
Jul 2014 -> Both Cells should be in red
Dec 2014
Dec 2014
Thank you for all the help.
have you tried conditional formatting ?
I don't know how to interpret this date format:
1394862706,
1394862645,
1400258321,
1400258250 etc. (each block is a different date)
Does someone understand in which format are them?
I believe they're Unix timestamps. For example, 1400258250 maps to 4:37:30 May 16 2014. They represent the number of seconds that have elapsed since the Unix epoch, January 1, 1970.
Here's a nice timestamp converter.
As others have noted, the 10-digit numbers are Unix timestamps, the number of seconds since 1970-01-01 00:00:00 +00:00, the Unix Epoch.
If you have GNU date, you can use the -d option (or --date) and the # prefix to analyze them (here, with TZ=US/Pacific or TZ=America/Los_Angeles):
$ for ts in 1394862706 1394862645 1400258321 1400258250; do date -d #$ts; done
Fri Mar 14 22:51:46 PDT 2014
Fri Mar 14 22:50:45 PDT 2014
Fri May 16 09:38:41 PDT 2014
Fri May 16 09:37:30 PDT 2014
$
If you add the -u or --utc option, then you get the output:
Sat Mar 15 05:51:46 UTC 2014
Sat Mar 15 05:50:45 UTC 2014
Fri May 16 16:38:41 UTC 2014
Fri May 16 16:37:30 UTC 2014