General SQL query for the Asterisk Call Detail Records database
SELECT calldate, did, src, cnam, CONCAT(dcontext, ',', dst) AS 'dst-context', disposition, duration, userfield, channel, dstchannel FROM cdr ORDER BY calldate DESC
SELECT calldate, did, src, cnam, CONCAT(dcontext, ',', dst) AS 'dst-context', disposition, duration, userfield, channel, dstchannel FROM cdr ORDER BY calldate DESC