[Serusers] timestamp field in ACC table

Ryan Pagquil rpagquil at philonline.com
Thu Sep 29 13:18:46 CEST 2005


Hi guys,
       I've just found out that the timestamp field in ACC table doesn't 
contain the real timestamp relative to 1970. It is just like the time 
field in ACC table but without the ":" and the "-" delimiters. So when I 
computed for the duration it doesn't give me the correct duration time. 
Here is the query I used to extract for duration:

SELECT t1.from_uri as CLR,  t1.to_uri as CLD, (t2.time - t1.time) as 
Duration,  t1.time as Setup_Time, t2.time as Release_Time FROM acc t1, 
acc t2 WHERE t1.sip_callid = t2.sip_callid AND ((t1.fromtag = t2.fromtag 
and t1.totag = t2.totag) OR (t1.fromtag = t2.totag and t1.totag = 
t2.fromtag)) AND t1.sip_method='ACK' AND t2.sip_method='BYE';

attached is a text file that contains one of the record in acc table.

Thanks,


Ryan Pagquil
Infodyne Inc. - PhilOnline.com
3603 Antel Global Corporate Center
Doña Julia Vargas Ave.
Ortigas Center Pasig City
Tel: 687-0715
Web: www.philonline.com

-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: acctable.txt
URL: <http://lists.sip-router.org/pipermail/sr-users/attachments/20050929/93ead0f8/attachment.txt>


More information about the sr-users mailing list