Questions tagged [utc]

UTC stands for Coordinated Universal Time - it is the time standard by which the world regulates clocks and time.

UTC stands for Coordinated Universal Time - it is the time standard by which the world regulates clocks and time.

Questions relating to UTC can relate to date-time formatting, conversions etc.

Definition taken from - WikiPedia

2332 questions
0
votes
1 answer

Epoch Date conversion different result on different computer

I'm having issues with Epoch Date conversion. I am using moment.js JavaScript library for this purpose. I have a UTC DateTime value in the Epoch format. When I run the same epoch conversion code on two different computers (using different timezones)…
theITvideos
  • 1,462
  • 2
  • 18
  • 29
0
votes
0 answers

JavaScript toISOString() sets the date a day previous to the user input date?

When I try to convert a user inputted date such as 05/13/1978 I want to send the date in ISO format to the server as that is what the back end accepts. new Date('05/13/1978); Outputs: Sat May 13 1978 00:00:00 GMT+0100 (British Summer Time) Which…
RyanP13
  • 7,413
  • 27
  • 96
  • 166
0
votes
0 answers

Javascript date conversion and daylight saving time

I am calling an Api that has the dates in the following format: 2020-09-08T00:00:00Z. I want to get the current date of the user and compare it against the API date to see how much time is left. The problem is that users could be in UK or IE and the…
retroman
  • 175
  • 1
  • 11
0
votes
3 answers

Python Pandas, converting datetime data into datetime.utc. whilst ignoring the timezones

I have a pandas dataframe with the following data: PointId Time Value 0 Brabrand1_1 2020-10-02 23:58:14+02 0.9754 1 Brabrand1_1 2020-02-23 21:03:00+01 2.1414 2 Brabrand1_1 2020-02-23 21:33:00+01 2.1406 3 …
0
votes
1 answer

Insert UTC date in Date type column

I want to insert UTC Date into my SQL Server table date type, my query is failing and here is my that fails Insert into Vendor(Vendor_id,Vendor_Name,LIC_START_DATE) VALUES('12345','XYZ','2020-01-01Z'); LIC_START_DATE is date…
hh PAT
  • 1
  • 5
0
votes
0 answers

Whats the difference in moment and moment.utc

I've run the 2 commands moment() and moment().utc() and I don't see any difference in the output, except the UTC object, has a flag is UTC set to true. Both return this - Tue Oct 06 2020 20:02:33 GMT+0100 What's the difference I should expect to be…
j obe
  • 1,759
  • 4
  • 15
  • 23
0
votes
2 answers

Timestamp as UTC Integer

I Have a legacy database with a field containing an integer representing a datetime in UTC From the documentation: "Timestamps within a CDR appear in Universal Coordinated Time (UTC). This value remains independent of daylight saving time…
jmw
  • 2,864
  • 5
  • 27
  • 32
0
votes
1 answer

Convert datetime.datetime from UTC to CEST one hour to less

If I run the following code I convert the datetime.datetime from utc to cest, but it does not work right. Correct would be if it would change from 21:29 to 23:29 because the time difference is 2 hours from_zone = tz.gettz('UTC') to_zone =…
padul
  • 134
  • 11
0
votes
1 answer

laravel scheduler executes jobs 2 hours later (I guess problem is UTC on the server)

I am trying to execute job daily at certain time, but it is always executed 2 hours later. The job just writes a log. If I use this scheduler: $schedule->job(new MyJob)->dailyAt('10:00'); The log is always written at 12:00AM. I have a vps with…
Giacomo M
  • 4,450
  • 7
  • 28
  • 57
0
votes
1 answer

What is logic of manipulation with timezones in Java/Kotlin?

Let's assume that I have client's time saved in my database as 2020-09-22T10:50:37.276240900 I need to present this date in web-service for client app depending on client timezone, for example I need to add 2 hours to saved date if client lives in…
Eugene Shmorgun
  • 2,083
  • 12
  • 42
  • 67
0
votes
0 answers

How to convert UTC Date to New Zeeland time zone in XSLT1.0?

I am trying to change a date from UTC format to the New Zeeland time zone. I was able to find a working solution, as shown in the following example: xsl:value-of select="xs:dateTime('2002-12-24T12:00:12Z')+xs:dayTimeDuration('PT12H')" Unfortunately,…
iwasaki
  • 77
  • 3
0
votes
1 answer

Convert UTC time to specific timezone client side

is it possible to convert a UTC date coming from a server to a specific (UK) timezone using JavaScript? This is for the case where users may have the incorrect local timezone configured.
isshesure
  • 213
  • 2
  • 10
0
votes
2 answers

How do you format current system datetime as UTC using String.format in Java?

This code String.format("%1$tY%1$tm%1$td", new Date()); gives a YYYYmmdd format using the current system time but the time zone is the current system default as well. How to make this code gives UTC date? I tried String.format("%1$tY%1$tm%1$td",…
user1589188
  • 5,316
  • 17
  • 67
  • 130
0
votes
1 answer

PyMongo/Python/Airflow - Convert CST Date/DateTime to UTC and store in MongoDB in ISO format?

Which is the correct or ideal or preferred method to convert a CST Date and/or Datetime field to UTC along with DST aware settings and store in MongoDB in ISO format in Python/PyMongo ? The source date/datetime field can come from any timezone…
ManiK
  • 377
  • 1
  • 21
0
votes
3 answers

getHours() and getUTCHours in Code by Zapier (JavaScript)

In a Code by Zapier task, how to I get the local time of a date/time provided in UTC. I am in time zone Europe/London. At the time of posting, owing to daylight saving, 9 AM London time is 8 AM UTC. But the following both return 8 when used in a…
colinp_1
  • 3
  • 5
1 2 3
99
100