update the datbase schema in gophon
Hello,
we need to update the database schema in gophon to make it work with http://www.cdr-stats.org/
and remove the gosa particularities
the schema is like this
create database asteriskcdrdb; use asteriskcdrdb;
CREATE TABLE cdr(
acctid integer NOT NULL AUTO_INCREMENT PRIMARY KEY,
src varchar(80) NOT NULL,
dst varchar(80) NOT NULL,
calldate datetime NOT NULL,
clid varchar(80) NOT NULL,
dcontext varchar(80) NOT NULL,
channel varchar(80) NOT NULL,
dstchannel varchar(80) NOT NULL,
lastapp varchar(80) NOT NULL,
lastdata varchar(80) NOT NULL,
duration integer unsigned NOT NULL,
billsec integer unsigned NOT NULL,
disposition integer unsigned NOT NULL,
amaflags integer unsigned NOT NULL,
accountcode integer unsigned NOT NULL,
uniqueid varchar(32) NOT NULL,
userfield varchar(80) NOT NULL
);
ALTER TABLE cdr ADD INDEX ( calldate );
ALTER TABLE cdr ADD INDEX ( dst );
ALTER TABLE cdr ADD INDEX ( accountcode );
we must add the correct rights of the db GRANT INSERT,SELECT ON asteriskcdrdb.cdr TO asterisk@localhost IDENTIFIED BY 'somemysqlpass';
(from redmine: issue id 631, created on 2012-02-22, closed on 2012-03-02)
- Changesets:
- Revision 6cb9780b by Benoit MORTIER on 2012-02-22T12:01:37.000Z:
refs: #631 update the datbase schema in gophon
- Revision da4737d7 by Benoit MORTIER on 2012-02-22T12:06:45.000Z:
refs: #631 update the datbase schema in gophon