<div dir="ltr">SELECT a.start_stamp,a.accountcode,a.caller_id_number,a.destination_number,a.hangup_cause,a.duration,a.sip_hangup_disposition as aleg_shd,b.sip_hangup_disposition as bleg_shd FROM pstn_cdr a INNER JOIN pstn_cdr b ON a.uuid=b.originating_leg_uuid<br><br></div><div class="gmail_extra"><br><div class="gmail_quote">On Tue, Jul 5, 2016 at 10:56 PM, Victor Chukalovskiy <span dir="ltr">&lt;<a href="mailto:victor.chukalovskiy@gmail.com" target="_blank">victor.chukalovskiy@gmail.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Good day, the scenario is that I have one a-leg and numerous b-legs for<br>
each call in my CDR. I need a simple way of selecting all leg for the<br>
same call at once<br>
<br>
Previously I&#39;ve relied on things like ${bleg_uuid}, ${last_bridge_to}<br>
etc. But it in the end it involves a 2-step process or inner join to put<br>
a- and b- legs together.<br>
<br>
What would really help is if there is a way to have an extra variabvle<br>
which will have the same value for every leg of the same call. Can<br>
someone tell me if such var already exists, or if I need to generate it<br>
myself and export to both a- and b- legs?<br>
<br>
Thank you,<br>
<br>
<br>
_________________________________________________________________________<br>
Professional FreeSWITCH Consulting Services:<br>
<a href="mailto:consulting@freeswitch.org">consulting@freeswitch.org</a><br>
<a href="http://www.freeswitchsolutions.com" rel="noreferrer" target="_blank">http://www.freeswitchsolutions.com</a><br>
<br>
Official FreeSWITCH Sites<br>
<a href="http://www.freeswitch.org" rel="noreferrer" target="_blank">http://www.freeswitch.org</a><br>
<a href="http://confluence.freeswitch.org" rel="noreferrer" target="_blank">http://confluence.freeswitch.org</a><br>
<a href="http://www.cluecon.com" rel="noreferrer" target="_blank">http://www.cluecon.com</a><br>
<br>
FreeSWITCH-users mailing list<br>
<a href="mailto:FreeSWITCH-users@lists.freeswitch.org">FreeSWITCH-users@lists.freeswitch.org</a><br>
<a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users" rel="noreferrer" target="_blank">http://lists.freeswitch.org/mailman/listinfo/freeswitch-users</a><br>
UNSUBSCRIBE:<a href="http://lists.freeswitch.org/mailman/options/freeswitch-users" rel="noreferrer" target="_blank">http://lists.freeswitch.org/mailman/options/freeswitch-users</a><br>
<a href="http://www.freeswitch.org" rel="noreferrer" target="_blank">http://www.freeswitch.org</a><br>
</blockquote></div><br></div>