Print Page | Close Window

Accounting for GMT in a CurrentDateTime

Printed From: Crystal Reports Book
Category: Crystal Reports 9 through 2020
Forum Name: Technical Questions
Forum Discription: Formulas, charting data, Crystal syntax, etc.
URL: http://www.crystalreportsbook.com/forum/forum_posts.asp?TID=2931
Printed Date: 06 May 2024 at 4:27pm


Topic: Accounting for GMT in a CurrentDateTime
Posted By: KJourneay
Subject: Accounting for GMT in a CurrentDateTime
Date Posted: 15 Apr 2008 at 9:56am
Hi,
 
Thanks in advance for any advice. I searched the forums, but I may not have been using the right keywords.
 
I am using this formula to get to turn around time (in seconds) for a work item in our database:
Datediff ("s", {wf_job_events.event_date}, mailto:%7b@CompleteDate - {@CompleteDate })
 
The @CompleteDate formula is:
If IsNull ({work_items.completion_date}) THEN
CurrentDateTime
Else {work_items.completion_date}
 
The business requirement is that we still need to generate a turnaround time for work items that are not complete yet (I end up higlighting the records in red to indicate that the item is still open).
 
Now this works great, unless the workitem is not yet completed.  The formula will generate a date, but CurrentDateTime is based on the PC time, and the time date stamp on the work item is based on GMT.
 
How do I make this formula evaluate CurrentDateTime at the server level?
Or another way to do it is to ask: Can I change CurrentDateTime to be GMT instead?
 
 



Print Page | Close Window