Skip to content

Instantly share code, notes, and snippets.

@wanghy6503
Created October 25, 2017 08:04
Show Gist options
  • Save wanghy6503/3f3fd625e4d28b38f47b4e636b4fe2f0 to your computer and use it in GitHub Desktop.
Save wanghy6503/3f3fd625e4d28b38f47b4e636b4fe2f0 to your computer and use it in GitHub Desktop.
asterisk cel logging schema
CREATE TABLE `cel` (
`id` BIGINT(20) UNSIGNED NOT NULL AUTO_INCREMENT,
`eventtype` VARCHAR(30) COLLATE utf8_unicode_ci NOT NULL,
`eventtime` TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
`userdeftype` VARCHAR(255) COLLATE utf8_unicode_ci NOT NULL,
`cid_name` VARCHAR(80) COLLATE utf8_unicode_ci NOT NULL,
`cid_num` VARCHAR(80) COLLATE utf8_unicode_ci NOT NULL,
`cid_ani` VARCHAR(80) COLLATE utf8_unicode_ci NOT NULL,
`cid_rdnis` VARCHAR(80) COLLATE utf8_unicode_ci NOT NULL,
`cid_dnid` VARCHAR(80) COLLATE utf8_unicode_ci NOT NULL,
`exten` VARCHAR(80) COLLATE utf8_unicode_ci NOT NULL,
`context` VARCHAR(80) COLLATE utf8_unicode_ci NOT NULL,
`channame` VARCHAR(80) COLLATE utf8_unicode_ci NOT NULL,
`appname` VARCHAR(80) COLLATE utf8_unicode_ci NOT NULL,
`appdata` VARCHAR(80) COLLATE utf8_unicode_ci NOT NULL,
`amaflags` INT(11) NOT NULL,
`accountcode` VARCHAR(20) COLLATE utf8_unicode_ci NOT NULL,
`peeraccount` VARCHAR(20) COLLATE utf8_unicode_ci NOT NULL,
`uniqueid` VARCHAR(150) COLLATE utf8_unicode_ci NOT NULL,
`linkedid` VARCHAR(150) COLLATE utf8_unicode_ci NOT NULL,
`userfield` VARCHAR(255) COLLATE utf8_unicode_ci NOT NULL,
`peer` VARCHAR(80) COLLATE utf8_unicode_ci NOT NULL,
UNIQUE KEY `id` (`id`)
) ENGINE=INNODB;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment