Timezone Conversion
Hi All, We have an external system where Remedy receives Updateds and create record in WorkLog of a form in Text format. In this text format a datetime information is stored as UTC Zero offset *2013-06-24T10:10:10 format.* *Now whenever User opens it, view the value instead of local time. * ** *Can you have any idea how to convert it to epoch timestamp or can it be changed to local timezone of user. * ** *Appreciate your help. * ** *Thanks * *Ziayn * ___ UNSUBSCRIBE or access ARSlist Archives at www.arslist.org Where the Answers Are, and have been for 20 years
Re: Timezone Conversion
Once you save a timestamp in a text field, it will never change because its now considered just text. The only way to get that value to change, to reflect the current time zone, is by storing it in a Date/Time field on the form. Then the Remedy system knows how to adjust. We have the same issues with email notifications. Once the date/time is put into the body of the email, it won't change to reflect the users zone. The solution in this case was to drop PST or EST after any time entries. For one of our clients, this is the first line of text in every email that goes out: Note: All Dates and Times (if applicable) are in Pacific Time Sent from my iPhone On 2013-06-23, at 11:23 PM, syed Ziyan syedziya...@gmail.com wrote: ** Hi All, We have an external system where Remedy receives Updateds and create record in WorkLog of a form in Text format. In this text format a datetime information is stored as UTC Zero offset 2013-06-24T10:10:10 format. Now whenever User opens it, view the value instead of local time. Can you have any idea how to convert it to epoch timestamp or can it be changed to local timezone of user. Appreciate your help. Thanks Ziayn _ARSlist: Where the Answers Are and have been for 20 years_ ___ UNSUBSCRIBE or access ARSlist Archives at www.arslist.org Where the Answers Are, and have been for 20 years
Re: Timezone Conversion
Syed- Are you passing the incoming e-mail directly to the destination form or does it pass through a staging form? If it passes through a staging form you should be able to parse the timestamp into a display-only date/time field, then push that field back into the update with the correct syntax before pushing to the destination form. That is an oversimplification but with some careful planning it should be possible. -Rick ___ Rick Westbrock QMX Support Services From: Action Request System discussion list(ARSList) [mailto:arslist@ARSLIST.ORG] On Behalf Of Brent Goodman Sent: Monday, June 24, 2013 0:53 AM To: arslist@ARSLIST.ORG Subject: Re: Timezone Conversion ** Once you save a timestamp in a text field, it will never change because its now considered just text. The only way to get that value to change, to reflect the current time zone, is by storing it in a Date/Time field on the form. Then the Remedy system knows how to adjust. We have the same issues with email notifications. Once the date/time is put into the body of the email, it won't change to reflect the users zone. The solution in this case was to drop PST or EST after any time entries. For one of our clients, this is the first line of text in every email that goes out: Note: All Dates and Times (if applicable) are in Pacific Time Sent from my iPhone On 2013-06-23, at 11:23 PM, syed Ziyan syedziya...@gmail.commailto:syedziya...@gmail.com wrote: ** Hi All, We have an external system where Remedy receives Updateds and create record in WorkLog of a form in Text format. In this text format a datetime information is stored as UTC Zero offset 2013-06-24T10:10:10 format. Now whenever User opens it, view the value instead of local time. Can you have any idea how to convert it to epoch timestamp or can it be changed to local timezone of user. Appreciate your help. Thanks Ziayn _ARSlist: Where the Answers Are and have been for 20 years_ _ARSlist: Where the Answers Are and have been for 20 years_ Important: This email is intended for the above named only and may be confidential, proprietary, and/or legally privileged. If this email has come to you in error, you must take no action on it, nor may you copy or show it to anyone. Please contact the sender and delete the material from any computer. ___ UNSUBSCRIBE or access ARSlist Archives at www.arslist.org Where the Answers Are, and have been for 20 years
Re: Timezone conversion
Hi Axton, Thanks for your feedback... Luckily, I only have to worry about the DST, not the localized date/time format... I looked into the BMC 7.6.04 Configuration Doc and it talked about the Business Times commands that take Daylight Saving Time (DST) into consideration. See “Application-Bus-Time2-Add” on page 235 for an example. $PROCESS$ Application-Bus-Time2-Add $fieldName$ amount amountUnits amount—Specifies an amount of time to offset the start time by. The amount can be an integer value of 0 or greater amountUnits—The unit of time, which can be set to 1 for seconds, 2 for minutes, 3 for hours, or 4 for days. Any other setting reverts to hours (3). With a filter, I used set field action: $PROCESS$ Application-Bus-Time2-Add $fieldName$ amount amountUnits where amount = Server Time Zone Offset From my initial testing, it looks OK, I have the date/time field set into appropriate time, but I'm not sure who the if there are any gotchas to using this process command: “Application-Bus-Time2-Add” . Thoughts? Thanks in advance.. Christianne ___ UNSUBSCRIBE or access ARSlist Archives at www.arslist.org attend wwrug11 www.wwrug.com ARSList: Where the Answers Are
Timezone conversion
Hi Listers, Has anybody done timezone conversion before via workflow? I need to convert a date/time field to specific timezones. I've created an integer field that contains this epoch time value: 1317877200 (Thu, 6 Oct 2011 05:00:00 UTC) I'd like to solicit feedback on how to do the conversion of this integer value (workflow driven manipulations) to display the appropriate timezones below: CST- GMT +10:00 - Australia, Sydney GMT +00:00 - Europe/London Thanks in advance for your help. Regards, Christianne ___ UNSUBSCRIBE or access ARSlist Archives at www.arslist.org attend wwrug11 www.wwrug.com ARSList: Where the Answers Are
Re: Timezone conversion
The ARSLIST archives will have hundreded of posts on this topic. On Fri, Oct 7, 2011 at 1:49 PM, Christianne csoukn...@columnit.com wrote: Hi Listers, Has anybody done timezone conversion before via workflow? I need to convert a date/time field to specific timezones. I've created an integer field that contains this epoch time value: 1317877200 (Thu, 6 Oct 2011 05:00:00 UTC) I'd like to solicit feedback on how to do the conversion of this integer value (workflow driven manipulations) to display the appropriate timezones below: CST- GMT +10:00 - Australia, Sydney GMT +00:00 - Europe/London Thanks in advance for your help. Regards, Christianne ___ UNSUBSCRIBE or access ARSlist Archives at www.arslist.org attend wwrug11 www.wwrug.com ARSList: Where the Answers Are ___ UNSUBSCRIBE or access ARSlist Archives at www.arslist.org attend wwrug11 www.wwrug.com ARSList: Where the Answers Are
Re: Timezone conversion
If you can express your timezone as an offset from GMT then the calculation is easy: epoch + 3600 * offset If you start to deal with all the fun nuances that come with timezones expressed as a geographic region it gets much more complicated and Remedy workflow is not a good way to deal with the conversion. See http://www.worldtimezone.com/daylight.html. DST makes this complicated. Java provides classes to deal with this and I would suggest using the filter plugin framework to deal with it in that case. Also, if you want to express the resulting date/time value in a localized format (e.g., m/d/y h:m:s vs. y/d/m h:m:s, etc.) then Remedy workflow is a poor choice for your solution. Go for something that has already done the legwork (e.g., Java). See http://en.wikipedia.org/wiki/Date_format_by_country for possible formats. Axton Grams On Fri, Oct 7, 2011 at 12:49 PM, Christianne csoukn...@columnit.com wrote: Hi Listers, Has anybody done timezone conversion before via workflow? I need to convert a date/time field to specific timezones. I've created an integer field that contains this epoch time value: 1317877200 (Thu, 6 Oct 2011 05:00:00 UTC) I'd like to solicit feedback on how to do the conversion of this integer value (workflow driven manipulations) to display the appropriate timezones below: CST- GMT +10:00 - Australia, Sydney GMT +00:00 - Europe/London Thanks in advance for your help. Regards, Christianne ___ UNSUBSCRIBE or access ARSlist Archives at www.arslist.org attend wwrug11 www.wwrug.com ARSList: Where the Answers Are ___ UNSUBSCRIBE or access ARSlist Archives at www.arslist.org attend wwrug11 www.wwrug.com ARSList: Where the Answers Are