Re: Storing Dates and Times From Different Time Zones

2018-12-21 Thread Kirk Brooks via 4D_Tech
https://www.youtube.com/watch?v=jgF_ycCmF18 It just had to be said. On Thu, Dec 20, 2018 at 6:04 PM Keisuke Miyako via 4D_Tech < 4d_tech@lists.4d.com> wrote: > is this a competition? > -- Kirk Brooks San Francisco, CA === *We go vote - they go home*

Re: Storing Dates and Times From Different Time Zones

2018-12-21 Thread Arnaud de Montard via 4D_Tech
> Le 20 déc. 2018 à 18:54, Nate Rheaume via 4D_Tech <4d_tech@lists.4d.com> a > écrit : > > We have clients that are accessing the same server database from different > time zones. We would like to store date/time using GMT and then display it in > the users local time zone. As I understand,

Re: Storing Dates and Times From Different Time Zones

2018-12-20 Thread Keisuke Miyako via 4D_Tech
this works for dates...but not very practical, obviously. C_DATE($d) C_TIME($t) $dbp:=Get database parameter(Dates inside objects) SET DATABASE PARAMETER(Dates inside objects;String type with time zone) $d:=JSON Parse("\""+$ISO+"\"";Is date) XML DECODE($ISO;$t) SET DATABASE PARAMETER(Dates

Re: Storing Dates and Times From Different Time Zones

2018-12-20 Thread Keisuke Miyako via 4D_Tech
oops! this works for the time but not the date! 2018/12/21 11:02、Keisuke Miyako via 4D_Tech <4d_tech@lists.4d.com>のメール: XML DECODE($ISO;$d) ** 4D Internet Users Group (4D iNUG) Archive:

Re: Storing Dates and Times From Different Time Zones

2018-12-20 Thread Keisuke Miyako via 4D_Tech
is this a competition? then here's my entry: $ISO:=String(Current date;ISO date GMT;Current time) C_DATE($d) C_TIME($t) XML DECODE($ISO;$d) XML DECODE($ISO;$t) ** 4D Internet Users Group (4D iNUG) Archive:

Re: Storing Dates and Times From Different Time Zones

2018-12-20 Thread John DeSoi via 4D_Tech
I use the code below to determine the number of seconds offset from GMT for the current time zone. This could be added back to a GMT time stamp to get the local time. John DeSoi, Ph.D. C_LONGINT($0) C_DATE($zDate;$gmtDate) C_TIME($zTime;$gmtTime) C_TEXT($str) $zDate:=Current date

RE: Storing Dates and Times From Different Time Zones

2018-12-20 Thread Timothy Penner via 4D_Tech
Tech Tip: Convert ISO GMT date string to local time, date and ISO date string http://kb.4d.com/assetid=77110 -Tim -Original Message- From: 4D_Tech <4d_tech-boun...@lists.4d.com> On Behalf Of Nate Rheaume via 4D_Tech Sent: Thursday, December 20, 2018 9:55 AM To: 4d_tech@lists.4d.com