timezone

time zone not changing when specified

↘锁芯ラ 提交于 2019-12-25 08:28:22
问题 I am working with dates and times in several data sets and am having issues with time zone conversion. All of the data sets are set to GMT but I need to move the time zones back to their respective location. I have tried several thing to move the times but have been unsuccessful. My first mistake may have been setting the system environment to GMT but upon taking this away the time zones did not convert. Any suggestions on how to get the time zones to convert would be great. I attempt the

JDBC give MySQL datetime in UTC

送分小仙女□ 提交于 2019-12-25 08:26:10
问题 My Java: Date parsedDate = dateFormat.parse(timestamp); Timestamp dbTimestamp = new Timestamp(parsedDate.getTime()); insertTimestampPreparedStatement.setTimestamp(3, dbTimestamp); PhpMyAdmin/MySQL always displays this in my local time, even when I do insertTimestampPreparedStatement.setTimestamp(3, dbTimestamp, Calendar.instance(TimeZone.getTimeZone("UTC")); I'm not sure if MySQL stores them aware of timezone, and the only way I checked this was updating a timezone row to NOW() directly in

Why current UTC time on my local server and UTC time on my hosting server are different?

人盡茶涼 提交于 2019-12-25 07:06:39
问题 I printed below code on my local server and on my hosting server but seems both displaying diff. time for UTC timezone. Please explain me. echo print gmdate("Y-m-d\TH:i:s\Z"); //Output on LOCAL SERVER: 2014-09-12T08:02:49Z1UTC //It is the correct one //Output on HOSTING SERVER: 2014-09-12T06:51:39Z1 回答1: Finally, I got the solution. Actually my server time is not sync with world clock. I needed to install NTP (Network Time Protocol) service on my server. I have installed on CentOs using below

Format A Date With Offset

让人想犯罪 __ 提交于 2019-12-25 06:08:36
问题 I am attempting to alter a string DateTime value with Offset. This is the procedure I have attempted, but in the end, both datetime & datetime1 print their initial values. My desired output is to format datetime1 to the proper Offset so that it mirrors datetime 01/10/2016 5:18 PM 01/10/2016 5:18 PM-05:00 string datetime = "2017-01-10T17:18:00-05:00"; string datetime1 = "1/10/2016 3:18:00 PM"; DateTimeOffset dateTimeOffset = DateTimeOffset.Parse(datetime); TimeSpan tspan = dateTimeOffset

Grails/Java new Date() different in GSP

白昼怎懂夜的黑 提交于 2019-12-25 05:46:18
问题 I'm running across something very strange. If i println new Date() in a controller the output is in UTC format (which is what I want). But when I print new Date() from a grails gsp the date is in EDT format and is off. I'm running my app on CentOS Linux 6.5 through Tomcat 7. The system date and hardware date is using UTC. Here is my Java version: java version "1.7.0_51" Java(TM) SE Runtime Environment (build 1.7.0_51-b13) Java HotSpot(TM) 64-Bit Server VM (build 24.51-b03, mixed mode) I've

Environment variables within a function

做~自己de王妃 提交于 2019-12-25 05:43:49
问题 I am trying to have consistent results within a function that I am using. However, since an array does not remember timezone info, this is a little harder than I expected. > Sys.setenv(TZ = "") > ISOdate(2015,1,1,1,tz='UTC') [1] "2015-01-01 01:00:00 UTC" > c(ISOdate(2015,1,1,1,tz='UTC')) [1] "2015-01-01 02:00:00 CET" > tz(c(ISOdate(2015,1,1,1,tz='UTC'))) [1] "" As you can see, the array drops the timezone information. This is annoying since other functions like day() of lubridate change

JQGrid date formatter not applying local time offset correctly : Grails

泄露秘密 提交于 2019-12-25 05:01:40
问题 I have a simple table in the DB (MySql) which contains the date in the standard Date format. I am doing a simple select in grails and rendering the output to a JSON format for the jqgrid to pick up. In jqgrid I have the following cell definition: {name : 'processedDate',width:110,formatter:'date', formatoptions: {srcformat: 'Y-m-dTH:i:sZ',newformat:'d/m/Y H:i'}} The date I expect to see on the screen is 31/03/2013 22:06 which is what is displayed in the mysqlworkbench which I get from another

JQGrid date formatter not applying local time offset correctly : Grails

感情迁移 提交于 2019-12-25 05:01:34
问题 I have a simple table in the DB (MySql) which contains the date in the standard Date format. I am doing a simple select in grails and rendering the output to a JSON format for the jqgrid to pick up. In jqgrid I have the following cell definition: {name : 'processedDate',width:110,formatter:'date', formatoptions: {srcformat: 'Y-m-dTH:i:sZ',newformat:'d/m/Y H:i'}} The date I expect to see on the screen is 31/03/2013 22:06 which is what is displayed in the mysqlworkbench which I get from another

PHP Startup: Timezone database is corrupt

孤街浪徒 提交于 2019-12-25 04:35:27
问题 I have juste updated my CentOS server. PHP is now at the 5.2.10 version (php-5.2.10-1.el5.remi.i386), and I have installed PECL Runkit. tzdata was updated too (tzdata-2009i-2.el5.noarch). Since the update, Apache refuse to start Here is the httpd/error.log [Wed Jul 08 11:40:21 2009] [notice] suEXEC mechanism enabled (wrapper: /usr/sbin/suexec) [Wed Jul 08 11:40:24 2009] [notice] Digest: generating secret for digest authentication ... [Wed Jul 08 11:40:24 2009] [notice] Digest: done PHP Strict

Want to change date format & timezone for DocuSign account

安稳与你 提交于 2019-12-25 04:21:57
问题 Is there any DocuSign REST API available to change date format and time zone information for DocuSign account ? 回答1: You'll need to be an administrator of the account you want to change: Login to the DocuSign account in question. Click the Profile drop-down in the top right. Select Go To Admin . Select Regional Settings on left hand side. Modify your date settings. 来源: https://stackoverflow.com/questions/38761417/want-to-change-date-format-timezone-for-docusign-account