· 8 years ago · Nov 15, 2017, 08:08 PM
1CREATE TABLE `center` (
2 `id` int(11) NOT NULL,
3 `center` varchar(20) DEFAULT NULL,
4 `county_id` int(11) DEFAULT NULL,
5 `enabled` tinyint(1) DEFAULT NULL
6) ENGINE=InnoDB DEFAULT CHARSET=utf8;
7
8SET FOREIGN_KEY_CHECKS=0;
9SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
10SET time_zone = "+00:00";
11
12
13/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
14/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
15/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
16/*!40101 SET NAMES utf8mb4 */;
17--
18-- Table structure for table `center`
19--
20
21DROP TABLE IF EXISTS `center`;
22CREATE TABLE `center` (
23 `id` int(11) NOT NULL,
24 `center` varchar(20) DEFAULT NULL,
25 `county_id` int(11) DEFAULT NULL,
26 `enabled` tinyint(1) DEFAULT NULL
27) ENGINE=InnoDB DEFAULT CHARSET=utf8;
28
29--
30-- RELATIONS FOR TABLE `center`:
31-- `county_id`
32-- `county` -> `id`
33--
34
35--
36-- Dumping data for table `center`
37--
38
39INSERT INTO `center` (`id`, `center`, `county_id`, `enabled`) VALUES
40(1, 'Tahoe City', 1, 1),
41(2, 'Squaw Valley', 1, 0),
42(3, 'Kings Beach', 1, 1),
43(4, 'Soda Springs', 1, 0),
44(5, 'Truckee', 2, 1),
45(6, 'Incline Village', 3, 1),
46(7, 'N/A', 8, 0);
47
48--
49-- Table structure for table `county`
50--
51
52DROP TABLE IF EXISTS `county`;
53CREATE TABLE `county` (
54 `id` int(11) NOT NULL,
55 `county` varchar(15) NOT NULL,
56 `enabled` tinyint(1) DEFAULT NULL
57) ENGINE=InnoDB DEFAULT CHARSET=utf8;
58
59--
60-- RELATIONS FOR TABLE `county`:
61--
62
63--
64-- Dumping data for table `county`
65--
66
67INSERT INTO `county` (`id`, `county`, `enabled`) VALUES
68(1, 'Placer', 1),
69(2, 'Nevada', 1),
70(3, 'Washoe', 1),
71(4, 'El Dorado', 1),
72(5, 'Douglas', 1),
73(6, 'Carson', 1),
74(7, 'Alpine', 1),
75(8, 'N/A', 0);
76
77
78--
79-- Indexes for table `center`
80--
81ALTER TABLE `center`
82 ADD PRIMARY KEY (`id`),
83 ADD KEY `IDX_40F0EB2485E73F45` (`county_id`);
84
85--
86-- Indexes for table `county`
87--
88ALTER TABLE `county`
89 ADD PRIMARY KEY (`id`);
90
91SET FOREIGN_KEY_CHECKS=1;
92
93/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
94/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
95/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;