Skip to Content

Archived discussions are read-only. Learn more about SAP Q&A

DateDiff on Timestamps in Same Table

Hi, all.  I've got a database I'm trying to get a datediff out of. The set up of the database is that one table is {table.transtype} with it being either "D, E, or A" and a corresponding {table.timestamp} that provides the timestamp. The other problem is that there can be either multiple or none of any of the time timestamps. For instance, someone is dispatched (D) but never en route so there is no (E or A) or someone is never dispatched but goes anyway (E & A) but no (D). I'm trying to set up a formula to allow me to get the datediff in seconds between D & E and again between E & A.  Beyond the basic math, I'd love if I could have it flag whenever there is no transtype or timstamp or return a null response rather than 0. For instance, if I have a field that shows the datediff for E to A but the unit never went on scene, it would return "N/A" or blank instead of 0. Any assistance is greatly appreciated.

Thanks,

Jon

Former Member
Former Member replied

Hello,

The below link is useful ;

Minutes "n" difference between two TimeStamp in the same Table

Exactly suitable your requirement. Please see once give more updates...

Regards,

DJ

0 View this answer in context
Not what you were looking for? View more on this topic or Ask a question