There's a couple of columns you can write to in the table, most notably accountcode and userfield. There is more info here.
http://www.voip-info.org/wiki/index.php?page=Asterisk+func+cdr I'm not sure about defining additional columns and writing to them through the dialplan but I don't think you can. Ish jonas kellens wrote: > Thanks for your reply. I saw that info also on voip-info.org. > > I was wondering if I could define other columns, like those used for > billing (as defined in my sip.conf). > > Jonas. > > > On Tue, 2009-06-23 at 09:22 +0100, Ishfaq Malik wrote: >> Hi >> >> The calldate column is the date and time of the call, here's the >> definition of the cdr table >> >> CREATE TABLE `cdr` ( >> `calldate` datetime NOT NULL default '0000-00-00 00:00:00', >> `clid` varchar(80) NOT NULL default '', >> `src` varchar(80) NOT NULL default '', >> `dst` varchar(80) NOT NULL default '', >> `dcontext` varchar(80) NOT NULL default '', >> `channel` varchar(80) NOT NULL default '', >> `dstchannel` varchar(80) NOT NULL default '', >> `lastapp` varchar(80) NOT NULL default '', >> `lastdata` varchar(80) NOT NULL default '', >> `duration` int(11) NOT NULL default '0', >> `billsec` int(11) NOT NULL default '0', >> `disposition` varchar(45) NOT NULL default '', >> `amaflags` int(11) NOT NULL default '0', >> `accountcode` varchar(20) NOT NULL default '', >> `userfield` varchar(255) NOT NULL default '' >> ); >> >> ALTER TABLE `cdr` ADD `uniqueid` VARCHAR(32) NOT NULL default ''; >> ALTER TABLE `cdr` ADD INDEX ( `calldate` ); >> ALTER TABLE `cdr` ADD INDEX ( `dst` ); >> ALTER TABLE `cdr` ADD INDEX ( `accountcode` ); >> >> >> I got that info from here >> >> http://www.voip-info.org/wiki/view/Asterisk+cdr+mysql >> >> Ish >> > ------------------------------------------------------------------------ > > _______________________________________________ > -- Bandwidth and Colocation Provided by http://www.api-digital.com -- > > asterisk-users mailing list > To UNSUBSCRIBE or update options visit: > http://lists.digium.com/mailman/listinfo/asterisk-users -- Ishfaq Malik Software Developer PackNet Ltd Office: 0161 660 3062 _______________________________________________ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
