How to split CDR in two records?

Hi,

I have some income calls that come to my system by private siptrunk. Then the number is being checked, some variables are set and client is put on IVR. One path is that this call is DIALed to specific number and goes out the system by different siptrunk. Afterwards whole this scenario arrives in one CDR line.

SRC of the caller, DST of the callee, CHANNEL and DSTCHANNEL are all fine. But I have here part of incoming call, up to the IVR and outgoing call from DIAL command. All in one CDR. DURATION and BILLSEC time represents these combined IN and OUT parts. For some report issues I would like to split it in two separate CDRs to know how long is the outgoing part. Is it possible? Is there any trick that allows me to do that? Any help would be nice…

Within Asterisk there is the ForkCDR dialplan application[1]. Whether it will do exactly what you want I don’t know, 'nor do I know its usage within FreePBX itself.

[1] Asterisk 18 Application_ForkCDR - Asterisk Project - Asterisk Project Wiki

Have you looked at the cel table linked on the ${UNIQUEID} ?

I know there are few cel record for every cdr record with detailed information. But I was wondering for some cdr trick that would make it much easier for me for report issues. Handling with cel in various scenarios won’t be simple. But thank you.

Yep, but it is for Asterisk 18 and I am on lower version.

I linked to the 18 page but the application is available in earlier versions.

oh thank you. I will check this out

This topic was automatically closed 31 days after the last reply. New replies are no longer allowed.