TT#62216 TT#62907 add id's to cdr_period_costs table

Change-Id: If5e04c64b8b5def0f3e9858f0db2939acc384ef5
changes/05/32205/2
Rene Krenn 6 years ago
parent 6b7772a024
commit 9f328f13fe

@ -1,7 +1,7 @@
use accounting;
create table cdr_period_costs (
id int(10) unsigned not null auto_increment,
contract_id int(11) unsigned not null,
period enum('month','day') not null,
period_date date not null,
@ -14,11 +14,16 @@ create table cdr_period_costs (
notify_status enum('new','notified') not null default 'new',
notified_at datetime default null,
first_cdr_start_time decimal(13,3) not null,
first_cdr_id int(10) unsigned,
last_cdr_start_time decimal(13,3) not null,
last_cdr_id int(10) unsigned,
primary key (contract_id, period, period_date, direction),
primary key (id),
unique key (contract_id, period, period_date, direction),
key cdrperiodcosts_pdfls (period, period_date, direction, fraud_limit_exceeded, notify_status),
key cdrperiodcosts_fstime (first_cdr_start_time)
key cdrperiodcosts_fstime (first_cdr_start_time),
key cdrperiodcosts_fcid (first_cdr_id),
key cdrperiodcosts_lcid (last_cdr_id)
) ENGINE=InnoDB DEFAULT CHARSET=utf8;

Loading…
Cancel
Save