`City` varchar(55) DEFAULT '',
`State` varchar(55) DEFAULT '',
`Country_Code` varchar(5) DEFAULT '',
`NPA` varchar(5) DEFAULT '',
`NXX` varchar(5) DEFAULT '',
`Tax` double(13,4) DEFAULT NULL,
`Cost` double(13,4) DEFAULT NULL,
`Call_Date` datetime DEFAULT NULL,
`Call_Time` time DEFAULT NULL,
`Incoming_Trunk` varchar(255) DEFAULT '',
`Outgoing_Trunk` varchar(255) DEFAULT '',
`Dialed_Digits` varchar(255) DEFAULT '',
`ANI_Digits` varchar(255) DEFAULT '',
`Call_Duration` int(11) DEFAULT NULL,
`Extension` varchar(255) DEFAULT '',
`Site_Timezone` varchar(15) DEFAULT ''
) ENGINE=Columnstore DEFAULT CHARSET=latin1;

select * from information_schema.columnstore_columns;

LOAD DATA LOCAL infile '423_cdr_avaya.txt' INTO TABLE `avaya`;

select * from information_schema.columnstore_extents;
SELECT COUNT(*) FROM `avaya` WHERE Site_Code='kch';

select * from information_schema.columnstore_extents;

--LOAD DATA LOCAL infile '423_avaya.problem' INTO TABLE `avaya`;
LOAD DATA LOCAL infile 'no-problem' INTO TABLE `avaya`;

select * from information_schema.columnstore_extents;

SELECT COUNT(*) FROM `avaya` WHERE Site_Code='kch';


