blob: bfd5279823c08e9f6a77f2c656c547ddad5c87fb [file] [log] [blame]
Brian Waters13d96012017-12-08 16:53:31 -06001--Can be used in phpMyAdmin
2
3SET SQL_MODE="NO_AUTO_VALUE_ON_ZERO";
4
5--
6-- DIAMETER SERVER DATABASE
7--
8
9-- --------------------------------------------------------
10
11--
12-- Table structure for table `ds_data_types`
13--
14
15CREATE TABLE IF NOT EXISTS `ds_data_types` (
16 `id_data_type` int(11) NOT NULL AUTO_INCREMENT,
17 `label_type` varchar(255) NOT NULL,
18 PRIMARY KEY (`id_data_type`)
19) ENGINE=MyISAM DEFAULT CHARSET=latin1 AUTO_INCREMENT=2 ;
20
21-- --------------------------------------------------------
22
23--
24-- Table structure for table `ds_networks`
25--
26
27CREATE TABLE IF NOT EXISTS `ds_networks` (
28 `id_network` int(11) NOT NULL AUTO_INCREMENT,
29 `label_network` varchar(255) NOT NULL,
30 PRIMARY KEY (`id_network`)
31) ENGINE=MyISAM DEFAULT CHARSET=latin1 AUTO_INCREMENT=3 ;
32
33-- --------------------------------------------------------
34
35--
36-- Table structure for table `ds_sip_aor`
37--
38
39CREATE TABLE IF NOT EXISTS `ds_sip_aor` (
40 `id_sip_aor` int(11) NOT NULL AUTO_INCREMENT,
41 `id_user` int(11) NOT NULL,
42 `sip_aor` varchar(255) NOT NULL,
43 `sip_server_uri` varchar(255) DEFAULT NULL,
44 `registered` tinyint(1) NOT NULL DEFAULT '0',
45 PRIMARY KEY (`id_sip_aor`,`id_user`)
46) ENGINE=InnoDB DEFAULT CHARSET=latin1 AUTO_INCREMENT=4 ;
47
48-- --------------------------------------------------------
49
50--
51-- Table structure for table `ds_sip_services`
52--
53
54CREATE TABLE IF NOT EXISTS `ds_sip_services` (
55 `id_service` int(11) NOT NULL AUTO_INCREMENT,
56 `label_service` varchar(255) NOT NULL,
57 PRIMARY KEY (`id_service`)
58) ENGINE=MyISAM DEFAULT CHARSET=latin1 AUTO_INCREMENT=2 ;
59
60-- --------------------------------------------------------
61
62--
63-- Table structure for table `ds_users`
64--
65
66CREATE TABLE IF NOT EXISTS `ds_users` (
67 `id_user` int(11) NOT NULL AUTO_INCREMENT,
68 `username` varchar(50) NOT NULL,
69 `password` varchar(50) NOT NULL,
70 `SIP_Server_URI` varchar(255) DEFAULT NULL,
71 `temp_SIP_Server_URI` varchar(255) DEFAULT NULL,
72 `authentication_pending` tinyint(1) NOT NULL DEFAULT '0',
73 `registrated` tinyint(1) NOT NULL DEFAULT '0',
74 PRIMARY KEY (`id_user`)
75) ENGINE=InnoDB DEFAULT CHARSET=latin1 AUTO_INCREMENT=2 ;
76
77-- --------------------------------------------------------
78
79--
80-- Table structure for table `ds_user_data`
81--
82
83CREATE TABLE IF NOT EXISTS `ds_user_data` (
84 `id_user_data` int(11) NOT NULL AUTO_INCREMENT,
85 `id_sip_aor` int(11) NOT NULL,
86 `id_data_type` int(11) NOT NULL,
87 `data` longblob NOT NULL,
88 PRIMARY KEY (`id_user_data`,`id_sip_aor`,`id_data_type`)
89) ENGINE=MyISAM DEFAULT CHARSET=latin1 AUTO_INCREMENT=3 ;
90
91-- --------------------------------------------------------
92
93--
94-- Table structure for table `ds_user_networks`
95--
96
97CREATE TABLE IF NOT EXISTS `ds_user_networks` (
98 `id_user_network` int(11) NOT NULL AUTO_INCREMENT,
99 `id_user` int(11) NOT NULL,
100 `id_network` int(11) NOT NULL,
101 PRIMARY KEY (`id_user_network`,`id_user`)
102) ENGINE=MyISAM DEFAULT CHARSET=latin1 AUTO_INCREMENT=3 ;
103
104-- --------------------------------------------------------
105
106--
107-- Table structure for table `ds_user_services`
108--
109
110CREATE TABLE IF NOT EXISTS `ds_user_services` (
111 `id_user_service` int(11) NOT NULL AUTO_INCREMENT,
112 `id_user` int(11) NOT NULL,
113 `id_service` int(11) NOT NULL,
114 `compulsory` tinyint(1) NOT NULL DEFAULT '0',
115 PRIMARY KEY (`id_user_service`,`id_user`)
116) ENGINE=MyISAM DEFAULT CHARSET=latin1 AUTO_INCREMENT=6 ;
117