[270] | 1 | SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
|
---|
| 2 | START TRANSACTION;
|
---|
| 3 | SET time_zone = "+00:00";
|
---|
[2] | 4 |
|
---|
[270] | 5 | /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
|
---|
| 6 | /*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
|
---|
| 7 | /*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
|
---|
| 8 | /*!40101 SET NAMES utf8mb4 */;
|
---|
| 9 |
|
---|
[394] | 10 | CREATE DATABASE IF NOT EXISTS `eleonline` DEFAULT CHARACTER SET latin1 COLLATE latin1_swedish_ci;
|
---|
| 11 | USE `eleonline`;
|
---|
[2] | 12 |
|
---|
| 13 | CREATE TABLE `soraldo_access` (
|
---|
| 14 | `access_id` int(10) NOT NULL,
|
---|
[270] | 15 | `access_title` varchar(20) DEFAULT NULL
|
---|
[394] | 16 | ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;
|
---|
[2] | 17 |
|
---|
[270] | 18 | INSERT INTO `soraldo_access` (`access_id`, `access_title`) VALUES
|
---|
| 19 | (1, 'Sospeso'),
|
---|
| 20 | (16, 'Operatore'),
|
---|
| 21 | (32, 'Amministratore'),
|
---|
| 22 | (64, 'Amministratore Unico'),
|
---|
| 23 | (256, 'Superuser');
|
---|
[2] | 24 |
|
---|
| 25 | CREATE TABLE `soraldo_authors` (
|
---|
[270] | 26 | `aid` varchar(25) NOT NULL DEFAULT '',
|
---|
| 27 | `name` varchar(50) DEFAULT NULL,
|
---|
[360] | 28 | `id_comune` int(11) NOT NULL DEFAULT 0,
|
---|
[270] | 29 | `email` varchar(255) DEFAULT NULL,
|
---|
| 30 | `pwd` varchar(40) DEFAULT NULL,
|
---|
[360] | 31 | `counter` int(11) NOT NULL DEFAULT 0,
|
---|
| 32 | `adminop` tinyint(2) NOT NULL DEFAULT 0,
|
---|
| 33 | `admincomune` tinyint(2) NOT NULL DEFAULT 0,
|
---|
| 34 | `adminsuper` tinyint(2) NOT NULL DEFAULT 0,
|
---|
[270] | 35 | `admlanguage` varchar(30) NOT NULL DEFAULT ''
|
---|
[394] | 36 | ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;
|
---|
[2] | 37 |
|
---|
[270] | 38 | INSERT INTO `soraldo_authors` (`aid`, `name`, `id_comune`, `email`, `pwd`, `counter`, `adminop`, `admincomune`, `adminsuper`, `admlanguage`) VALUES
|
---|
[394] | 39 | ('suser', 'suser', 0, 'test@eleonline.it', '098f6bcd4621d373cade4e832627b4f6', 1, 0, 0, 1, 'it');
|
---|
[2] | 40 |
|
---|
| 41 | CREATE TABLE `soraldo_config` (
|
---|
[270] | 42 | `sitename` varchar(255) NOT NULL DEFAULT '',
|
---|
| 43 | `siteurl` varchar(255) NOT NULL DEFAULT '',
|
---|
| 44 | `site_logo` varchar(255) NOT NULL DEFAULT '',
|
---|
| 45 | `slogan` varchar(255) NOT NULL DEFAULT '',
|
---|
| 46 | `startdate` varchar(50) NOT NULL DEFAULT '',
|
---|
| 47 | `adminmail` varchar(255) NOT NULL DEFAULT '',
|
---|
[360] | 48 | `tema` varchar(25) NOT NULL DEFAULT '',
|
---|
| 49 | `foot` mediumtext NOT NULL,
|
---|
| 50 | `language` char(3) NOT NULL DEFAULT '',
|
---|
| 51 | `blocco` enum('0','1') NOT NULL DEFAULT '0',
|
---|
| 52 | `testata` blob DEFAULT NULL,
|
---|
| 53 | `nome_testata` varchar(50) NOT NULL DEFAULT '',
|
---|
| 54 | `fileout` varchar(255) NOT NULL DEFAULT '',
|
---|
| 55 | `copyright` mediumtext NOT NULL,
|
---|
| 56 | `versione` int(3) DEFAULT NULL,
|
---|
| 57 | `patch` int(3) NOT NULL DEFAULT 0,
|
---|
| 58 | `siteistat` int(11) NOT NULL DEFAULT 0,
|
---|
| 59 | `multicomune` enum('0','1') NOT NULL DEFAULT '0',
|
---|
| 60 | `flash` enum('0','1') NOT NULL DEFAULT '0',
|
---|
| 61 | `displayerrors` enum('0','1') NOT NULL DEFAULT '0',
|
---|
| 62 | `gkey` varchar(100) NOT NULL DEFAULT '',
|
---|
| 63 | `googlemaps` enum('0','1') NOT NULL DEFAULT '0',
|
---|
[270] | 64 | `editor` enum('0','1') NOT NULL DEFAULT '1',
|
---|
| 65 | `tema_on` enum('0','1') NOT NULL DEFAULT '1',
|
---|
[362] | 66 | `ed_user` varchar(25) NOT NULL DEFAULT ''
|
---|
[394] | 67 | ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;
|
---|
[2] | 68 |
|
---|
[394] | 69 | INSERT INTO `soraldo_config` (`sitename`, `siteurl`, `site_logo`, `slogan`, `startdate`, `adminmail`, `tema`, `foot`, `language`, `blocco`, `testata`, `nome_testata`, `fileout`, `copyright`, `versione`, `patch`, `siteistat`, `multicomune`, `flash`, `displayerrors`, `gkey`, `googlemaps`, `editor`, `tema_on`, `ed_user`) VALUES
|
---|
| 70 | ('Elezioni On Line', 'http://localhost/ele3/trunk/client', '', 'Sito istituzionale', 'March 2023', 'test@eleonline.it', 'default', '', 'it', '1', '', '', '', 'Gpl v3', 3, 0, 58047, '0', '0', '0', '', '0', '1', '1', 'Admin');
|
---|
[2] | 71 |
|
---|
| 72 | CREATE TABLE `soraldo_doc_cons` (
|
---|
[360] | 73 | `id_cons` int(11) NOT NULL DEFAULT 0,
|
---|
| 74 | `id_doc` int(11) NOT NULL DEFAULT 0,
|
---|
| 75 | `tabella` varchar(25) NOT NULL DEFAULT ''
|
---|
[394] | 76 | ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;
|
---|
[2] | 77 |
|
---|
| 78 | CREATE TABLE `soraldo_ele_candidati` (
|
---|
[270] | 79 | `id_cand` int(11) NOT NULL,
|
---|
[360] | 80 | `id_cons` int(11) NOT NULL DEFAULT 0,
|
---|
| 81 | `id_lista` int(11) NOT NULL DEFAULT 0,
|
---|
| 82 | `num_lista` int(2) UNSIGNED NOT NULL,
|
---|
[270] | 83 | `cognome` varchar(50) DEFAULT NULL,
|
---|
| 84 | `nome` varchar(50) DEFAULT NULL,
|
---|
[360] | 85 | `note` text NOT NULL,
|
---|
[270] | 86 | `simbolo` varchar(30) NOT NULL DEFAULT '',
|
---|
[360] | 87 | `num_cand` int(7) NOT NULL DEFAULT 0
|
---|
[394] | 88 | ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;
|
---|
[2] | 89 |
|
---|
| 90 | CREATE TABLE `soraldo_ele_circoscrizione` (
|
---|
[360] | 91 | `id_cons` int(11) NOT NULL DEFAULT 0,
|
---|
[270] | 92 | `id_circ` int(11) NOT NULL,
|
---|
[360] | 93 | `num_circ` int(7) NOT NULL DEFAULT 0,
|
---|
| 94 | `descrizione` mediumtext DEFAULT NULL
|
---|
[394] | 95 | ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;
|
---|
[2] | 96 |
|
---|
| 97 | CREATE TABLE `soraldo_ele_collegi` (
|
---|
[270] | 98 | `id_collegio` int(11) NOT NULL,
|
---|
[360] | 99 | `id_cons_gen` int(11) NOT NULL DEFAULT 0,
|
---|
| 100 | `descrizione` mediumtext DEFAULT NULL
|
---|
[394] | 101 | ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;
|
---|
[2] | 102 |
|
---|
| 103 | CREATE TABLE `soraldo_ele_come` (
|
---|
[360] | 104 | `id_cons` int(11) NOT NULL DEFAULT 0,
|
---|
[270] | 105 | `mid` int(7) NOT NULL,
|
---|
[394] | 106 | `title` varchar(150) NOT NULL DEFAULT ' ',
|
---|
| 107 | `preamble` text DEFAULT NULL,
|
---|
| 108 | `content` text DEFAULT NULL,
|
---|
| 109 | `editimage` varchar(100) NOT NULL DEFAULT ' '
|
---|
| 110 | ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;
|
---|
[2] | 111 |
|
---|
| 112 | CREATE TABLE `soraldo_ele_comuni` (
|
---|
[360] | 113 | `id_comune` int(11) NOT NULL DEFAULT 0,
|
---|
[270] | 114 | `descrizione` varchar(50) DEFAULT NULL,
|
---|
| 115 | `indirizzo` varchar(50) DEFAULT NULL,
|
---|
| 116 | `centralino` varchar(15) DEFAULT NULL,
|
---|
| 117 | `fax` varchar(15) DEFAULT NULL,
|
---|
| 118 | `email` varchar(50) DEFAULT NULL,
|
---|
[360] | 119 | `fascia` tinyint(4) NOT NULL DEFAULT 0,
|
---|
[270] | 120 | `capoluogo` enum('0','1') NOT NULL DEFAULT '0',
|
---|
[360] | 121 | `simbolo` mediumtext DEFAULT NULL,
|
---|
| 122 | `stemma` blob DEFAULT NULL,
|
---|
| 123 | `id_cons` int(11) DEFAULT 0,
|
---|
| 124 | `cap` mediumtext DEFAULT NULL
|
---|
[394] | 125 | ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;
|
---|
[2] | 126 |
|
---|
[394] | 127 | INSERT INTO `soraldo_ele_comuni` (`id_comune`, `descrizione`, `indirizzo`, `centralino`, `fax`, `email`, `fascia`, `capoluogo`, `simbolo`, `stemma`, `id_cons`, `cap`) VALUES
|
---|
| 128 | (58047, 'Guidonia', '', '', '', '', 5, '0', '', '', 0, '');
|
---|
[270] | 129 |
|
---|
| 130 | CREATE TABLE `soraldo_ele_comu_collegi` (
|
---|
[360] | 131 | `id_collegio` int(11) NOT NULL DEFAULT 0,
|
---|
| 132 | `id_cons` int(11) NOT NULL DEFAULT 0,
|
---|
| 133 | `id_comune` int(11) NOT NULL DEFAULT 0,
|
---|
| 134 | `id_cons_gen` int(11) NOT NULL DEFAULT 0
|
---|
[394] | 135 | ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;
|
---|
[2] | 136 |
|
---|
| 137 | CREATE TABLE `soraldo_ele_conf` (
|
---|
[270] | 138 | `id_conf` int(11) NOT NULL,
|
---|
[2] | 139 | `descrizione` varchar(50) NOT NULL,
|
---|
| 140 | `limite` int(2) NOT NULL,
|
---|
[189] | 141 | `consin` enum('0','1') NOT NULL DEFAULT '1',
|
---|
[2] | 142 | `infpremio` int(3) NOT NULL,
|
---|
| 143 | `supsbarramento` int(3) NOT NULL,
|
---|
| 144 | `suppremio` int(3) NOT NULL,
|
---|
[360] | 145 | `listinfsbar` int(3) NOT NULL DEFAULT 1,
|
---|
[189] | 146 | `listinfconta` enum('0','1') NOT NULL DEFAULT '1',
|
---|
| 147 | `listsupconta` enum('0','1') NOT NULL DEFAULT '1',
|
---|
[2] | 148 | `supminpremio` int(3) NOT NULL,
|
---|
| 149 | `infminpremio` int(3) NOT NULL,
|
---|
[139] | 150 | `infdisgiunto` enum('0','1') NOT NULL DEFAULT '0',
|
---|
| 151 | `supdisgiunto` enum('0','1') NOT NULL DEFAULT '0',
|
---|
[189] | 152 | `votolista` enum('0','1') NOT NULL DEFAULT '0',
|
---|
| 153 | `inffisso` enum('0','1') NOT NULL DEFAULT '0',
|
---|
| 154 | `supfisso` enum('0','1') NOT NULL DEFAULT '0',
|
---|
[360] | 155 | `fascia_capoluogo` int(2) NOT NULL DEFAULT 0
|
---|
[394] | 156 | ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;
|
---|
[2] | 157 |
|
---|
[189] | 158 | INSERT INTO `soraldo_ele_conf` (`id_conf`, `descrizione`, `limite`, `consin`, `infpremio`, `supsbarramento`, `suppremio`, `listinfsbar`, `listinfconta`, `listsupconta`, `supminpremio`, `infminpremio`, `infdisgiunto`, `supdisgiunto`, `votolista`, `inffisso`, `supfisso`, `fascia_capoluogo`) VALUES
|
---|
| 159 | (1, 'Legge Italiana 267/2000', 3, '1', 67, 3, 60, 3, '1', '1', 40, 40, '0', '0', '0', '0', '0', 6),
|
---|
| 160 | (2, 'Regione Sicilia precedente al 2008', 2, '0', 67, 3, 60, 3, '1', '1', 40, 40, '0', '0', '0', '0', '0', 6),
|
---|
| 161 | (3, 'Regione Sicilia Legge n. 22 del 16/12/2008', 2, '0', 67, 5, 60, 3, '1', '0', 40, 40, '0', '0', '0', '0', '0', 7),
|
---|
[394] | 162 | (4, 'Regione Sicilia Legge n.6/2011', 5, '1', 67, 5, 60, 5, '1', '1', 40, 40, '1', '1', '0', '1', '0', 7),
|
---|
[189] | 163 | (5, 'Legge Italiana 267/2000 con riduzione 2011', 3, '1', 67, 3, 60, 3, '1', '1', 40, 40, '0', '0', '0', '0', '0', 7),
|
---|
[201] | 164 | (6, 'Legge Italiana 267/2000 con riduzione 2012', 3, '1', 67, 3, 60, 3, '1', '1', 40, 40, '0', '0', '0', '0', '0', 7),
|
---|
[199] | 165 | (7, 'Legge Italiana 267/2000 con modifiche 2014', 3, '1', 67, 3, 60, 3, '1', '1', 40, 40, '0', '0', '0', '0', '0', 6);
|
---|
[2] | 166 |
|
---|
[270] | 167 | CREATE TABLE `soraldo_ele_consultazione` (
|
---|
| 168 | `id_cons_gen` int(11) NOT NULL,
|
---|
[360] | 169 | `descrizione` mediumtext DEFAULT NULL,
|
---|
[270] | 170 | `data_inizio` date DEFAULT NULL,
|
---|
| 171 | `data_fine` date DEFAULT NULL,
|
---|
[360] | 172 | `tipo_cons` int(7) NOT NULL DEFAULT 0
|
---|
[394] | 173 | ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;
|
---|
[2] | 174 |
|
---|
[270] | 175 | CREATE TABLE `soraldo_ele_cons_comune` (
|
---|
| 176 | `id_cons` int(11) NOT NULL,
|
---|
| 177 | `chiusa` set('0','1','2') NOT NULL DEFAULT '0',
|
---|
[360] | 178 | `id_comune` int(11) NOT NULL DEFAULT 0,
|
---|
| 179 | `id_cons_gen` int(11) NOT NULL DEFAULT 0,
|
---|
| 180 | `id_conf` int(11) NOT NULL DEFAULT 0,
|
---|
[270] | 181 | `preferita` enum('0','1') NOT NULL DEFAULT '0',
|
---|
[360] | 182 | `preferenze` tinyint(1) NOT NULL DEFAULT 1,
|
---|
| 183 | `id_fascia` int(2) NOT NULL DEFAULT 1,
|
---|
[270] | 184 | `vismf` enum('0','1') NOT NULL DEFAULT '0',
|
---|
[360] | 185 | `solo_gruppo` enum('0','1') DEFAULT '0',
|
---|
[413] | 186 | `disgiunto` enum('0','1') NOT NULL DEFAULT '0',
|
---|
| 187 | `proiezione` ENUM('0','1') NOT NULL DEFAULT '0';
|
---|
[394] | 188 | ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;
|
---|
[2] | 189 |
|
---|
[270] | 190 | CREATE TABLE `soraldo_ele_controlli` (
|
---|
| 191 | `id_cons` int(11) NOT NULL,
|
---|
| 192 | `id_sez` int(11) NOT NULL,
|
---|
| 193 | `tipo` varchar(10) NOT NULL,
|
---|
| 194 | `id` int(11) NOT NULL
|
---|
[394] | 195 | ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;
|
---|
[2] | 196 |
|
---|
| 197 | CREATE TABLE `soraldo_ele_documenti` (
|
---|
[270] | 198 | `id_doc` int(11) NOT NULL,
|
---|
[360] | 199 | `descrizione` varchar(50) NOT NULL DEFAULT '',
|
---|
| 200 | `nomedoc` varchar(25) NOT NULL DEFAULT '',
|
---|
[270] | 201 | `filedoc` blob NOT NULL
|
---|
[394] | 202 | ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;
|
---|
[2] | 203 |
|
---|
| 204 | CREATE TABLE `soraldo_ele_fasce` (
|
---|
| 205 | `id_fascia` int(2) NOT NULL,
|
---|
| 206 | `abitanti` int(11) NOT NULL,
|
---|
| 207 | `seggi` int(4) NOT NULL,
|
---|
[360] | 208 | `id_conf` int(11) DEFAULT 1
|
---|
[394] | 209 | ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;
|
---|
[2] | 210 |
|
---|
[270] | 211 | INSERT INTO `soraldo_ele_fasce` (`id_fascia`, `abitanti`, `seggi`, `id_conf`) VALUES
|
---|
[189] | 212 | (1, 3000, 12, 1),
|
---|
| 213 | (2, 10000, 16, 1),
|
---|
| 214 | (3, 15000, 20, 1),
|
---|
| 215 | (4, 30000, 20, 1),
|
---|
| 216 | (5, 100000, 30, 1),
|
---|
| 217 | (6, 250000, 40, 1),
|
---|
| 218 | (7, 500000, 46, 1),
|
---|
| 219 | (8, 1000000, 50, 1),
|
---|
| 220 | (9, 100000000, 60, 1),
|
---|
| 221 | (1, 3000, 12, 2),
|
---|
| 222 | (2, 10000, 16, 2),
|
---|
| 223 | (3, 15000, 20, 2),
|
---|
| 224 | (4, 30000, 20, 2),
|
---|
| 225 | (5, 100000, 30, 2),
|
---|
| 226 | (6, 250000, 40, 2),
|
---|
| 227 | (7, 500000, 46, 2),
|
---|
| 228 | (8, 1000000, 50, 2),
|
---|
| 229 | (9, 100000000, 60, 2),
|
---|
| 230 | (1, 3000, 9, 3),
|
---|
| 231 | (2, 5000, 9, 3),
|
---|
| 232 | (4, 15000, 16, 3),
|
---|
| 233 | (3, 10000, 12, 3),
|
---|
| 234 | (5, 30000, 16, 3),
|
---|
| 235 | (6, 100000, 24, 3),
|
---|
| 236 | (7, 250000, 32, 3),
|
---|
| 237 | (8, 500000, 36, 3),
|
---|
| 238 | (9, 1000000, 40, 3),
|
---|
| 239 | (10, 100000000, 48, 3),
|
---|
| 240 | (1, 3000, 6, 4),
|
---|
| 241 | (2, 5000, 7, 4),
|
---|
| 242 | (3, 10000, 12, 4),
|
---|
| 243 | (4, 15000, 16, 4),
|
---|
| 244 | (5, 30000, 16, 4),
|
---|
| 245 | (6, 100000, 24, 4),
|
---|
| 246 | (7, 250000, 32, 4),
|
---|
| 247 | (8, 500000, 36, 4),
|
---|
| 248 | (9, 1000000, 40, 4),
|
---|
[199] | 249 | (10, 100000000, 48, 4),
|
---|
| 250 | (1, 3000, 9, 5),
|
---|
| 251 | (2, 5000, 9, 5),
|
---|
| 252 | (3, 10000, 12, 5),
|
---|
| 253 | (4, 15000, 16, 5),
|
---|
| 254 | (5, 30000, 16, 5),
|
---|
| 255 | (6, 100000, 24, 5),
|
---|
| 256 | (7, 250000, 32, 5),
|
---|
| 257 | (8, 500000, 36, 5),
|
---|
| 258 | (9, 1000000, 40, 5),
|
---|
| 259 | (10, 100000000, 48, 5),
|
---|
| 260 | (1, 3000, 6, 6),
|
---|
| 261 | (2, 5000, 7, 6),
|
---|
| 262 | (3, 10000, 10, 6),
|
---|
| 263 | (4, 15000, 16, 6),
|
---|
| 264 | (5, 30000, 16, 6),
|
---|
| 265 | (6, 100000, 24, 6),
|
---|
| 266 | (7, 250000, 32, 6),
|
---|
| 267 | (8, 500000, 36, 6),
|
---|
| 268 | (9, 1000000, 40, 6),
|
---|
| 269 | (10, 100000000, 48, 6),
|
---|
| 270 | (1, 3000, 10, 7),
|
---|
| 271 | (2, 10000, 12, 7),
|
---|
| 272 | (3, 15000, 16, 7),
|
---|
| 273 | (4, 30000, 16, 7),
|
---|
| 274 | (5, 100000, 24, 7),
|
---|
| 275 | (6, 250000, 32, 7),
|
---|
| 276 | (7, 500000, 36, 7),
|
---|
| 277 | (8, 1000000, 40, 7),
|
---|
| 278 | (9, 100000000, 48, 7);
|
---|
[2] | 279 |
|
---|
| 280 | CREATE TABLE `soraldo_ele_gruppo` (
|
---|
[360] | 281 | `id_cons` int(11) NOT NULL DEFAULT 0,
|
---|
[270] | 282 | `id_gruppo` int(11) NOT NULL,
|
---|
[360] | 283 | `num_gruppo` int(7) NOT NULL DEFAULT 0,
|
---|
| 284 | `descrizione` mediumtext DEFAULT NULL,
|
---|
| 285 | `simbolo` mediumtext DEFAULT NULL,
|
---|
| 286 | `stemma` blob DEFAULT NULL,
|
---|
| 287 | `id_circ` int(11) NOT NULL DEFAULT 0,
|
---|
| 288 | `num_circ` int(2) UNSIGNED NOT NULL DEFAULT 1,
|
---|
| 289 | `prognome` mediumtext DEFAULT NULL,
|
---|
| 290 | `programma` mediumblob DEFAULT NULL
|
---|
[394] | 291 | ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;
|
---|
[2] | 292 |
|
---|
[270] | 293 | CREATE TABLE `soraldo_ele_link` (
|
---|
[360] | 294 | `id_cons` int(11) NOT NULL DEFAULT 0,
|
---|
[270] | 295 | `mid` int(7) NOT NULL,
|
---|
[394] | 296 | `title` varchar(150) NOT NULL DEFAULT ' ',
|
---|
| 297 | `preamble` text DEFAULT NULL,
|
---|
| 298 | `content` text DEFAULT NULL,
|
---|
| 299 | `editimage` varchar(100) NOT NULL DEFAULT ' '
|
---|
| 300 | ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;
|
---|
[2] | 301 |
|
---|
[270] | 302 | CREATE TABLE `soraldo_ele_lista` (
|
---|
[360] | 303 | `id_cons` int(11) NOT NULL DEFAULT 0,
|
---|
[270] | 304 | `id_lista` int(11) NOT NULL,
|
---|
[360] | 305 | `num_lista` int(7) NOT NULL DEFAULT 0,
|
---|
| 306 | `id_gruppo` int(11) NOT NULL DEFAULT 0,
|
---|
| 307 | `num_gruppo` int(2) UNSIGNED NOT NULL DEFAULT 0,
|
---|
| 308 | `id_circ` int(11) NOT NULL DEFAULT 0,
|
---|
| 309 | `num_circ` int(2) UNSIGNED NOT NULL DEFAULT 1,
|
---|
| 310 | `descrizione` text DEFAULT NULL,
|
---|
| 311 | `simbolo` mediumtext DEFAULT NULL,
|
---|
| 312 | `stemma` blob DEFAULT NULL
|
---|
[394] | 313 | ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;
|
---|
[2] | 314 |
|
---|
[270] | 315 | CREATE TABLE `soraldo_ele_log` (
|
---|
| 316 | `id_cons` int(11) DEFAULT NULL,
|
---|
| 317 | `id_sez` int(11) DEFAULT NULL,
|
---|
| 318 | `utente` varchar(20) DEFAULT NULL,
|
---|
| 319 | `data` date DEFAULT NULL,
|
---|
| 320 | `ora` time DEFAULT NULL,
|
---|
[360] | 321 | `log_da` mediumtext DEFAULT NULL,
|
---|
| 322 | `log_a` mediumtext DEFAULT NULL,
|
---|
[270] | 323 | `tabella` varchar(30) DEFAULT NULL
|
---|
[394] | 324 | ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;
|
---|
[2] | 325 |
|
---|
[270] | 326 | CREATE TABLE `soraldo_ele_modelli` (
|
---|
[360] | 327 | `id_cons` int(11) NOT NULL DEFAULT 0,
|
---|
[270] | 328 | `categoria` varchar(20) NOT NULL DEFAULT '',
|
---|
| 329 | `modello` blob NOT NULL
|
---|
[394] | 330 | ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;
|
---|
[2] | 331 |
|
---|
[270] | 332 | CREATE TABLE `soraldo_ele_numeri` (
|
---|
[360] | 333 | `id_cons` int(11) NOT NULL DEFAULT 0,
|
---|
[270] | 334 | `mid` int(7) NOT NULL,
|
---|
| 335 | `title` varchar(150) NOT NULL DEFAULT '',
|
---|
[360] | 336 | `preamble` mediumtext NOT NULL,
|
---|
| 337 | `content` mediumtext NOT NULL,
|
---|
[270] | 338 | `editimage` varchar(100) NOT NULL DEFAULT ''
|
---|
[394] | 339 | ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;
|
---|
[2] | 340 |
|
---|
[270] | 341 | CREATE TABLE `soraldo_ele_operatori` (
|
---|
[360] | 342 | `id_cons` int(11) NOT NULL DEFAULT 0,
|
---|
| 343 | `id_sede` int(11) NOT NULL DEFAULT 0,
|
---|
| 344 | `id_comune` int(11) NOT NULL DEFAULT 0,
|
---|
[270] | 345 | `permessi` int(3) DEFAULT NULL,
|
---|
[360] | 346 | `aid` varchar(25) NOT NULL DEFAULT '',
|
---|
| 347 | `id_circ` int(11) NOT NULL DEFAULT 0,
|
---|
| 348 | `id_sez` int(11) NOT NULL DEFAULT 0
|
---|
[394] | 349 | ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;
|
---|
[2] | 350 |
|
---|
[270] | 351 | CREATE TABLE `soraldo_ele_province` (
|
---|
[360] | 352 | `id` tinyint(11) NOT NULL DEFAULT 0,
|
---|
| 353 | `descrizione` varchar(30) NOT NULL DEFAULT ''
|
---|
[394] | 354 | ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;
|
---|
[2] | 355 |
|
---|
[270] | 356 | CREATE TABLE `soraldo_ele_regioni` (
|
---|
[360] | 357 | `id` int(11) NOT NULL DEFAULT 0,
|
---|
| 358 | `descrizione` varchar(25) NOT NULL DEFAULT ''
|
---|
[394] | 359 | ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;
|
---|
[2] | 360 |
|
---|
[270] | 361 | CREATE TABLE `soraldo_ele_rilaff` (
|
---|
[360] | 362 | `id_cons_gen` int(11) NOT NULL DEFAULT 0,
|
---|
[270] | 363 | `orario` time NOT NULL DEFAULT '00:00:00',
|
---|
[394] | 364 | `data` date NOT NULL DEFAULT '1900-01-01'
|
---|
| 365 | ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;
|
---|
[2] | 366 |
|
---|
[270] | 367 | CREATE TABLE `soraldo_ele_sede` (
|
---|
[360] | 368 | `id_cons` int(11) NOT NULL DEFAULT 0,
|
---|
[270] | 369 | `id_sede` int(11) NOT NULL,
|
---|
[360] | 370 | `id_circ` int(11) NOT NULL DEFAULT 0,
|
---|
[270] | 371 | `indirizzo` varchar(60) DEFAULT NULL,
|
---|
| 372 | `telefono1` varchar(12) DEFAULT NULL,
|
---|
| 373 | `telefono2` varchar(12) DEFAULT NULL,
|
---|
| 374 | `fax` varchar(12) DEFAULT NULL,
|
---|
| 375 | `responsabile` varchar(60) DEFAULT NULL,
|
---|
| 376 | `mappa` mediumblob NOT NULL,
|
---|
| 377 | `filemappa` varchar(100) NOT NULL DEFAULT ''
|
---|
[394] | 378 | ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;
|
---|
[270] | 379 |
|
---|
| 380 | CREATE TABLE `soraldo_ele_servizi` (
|
---|
[360] | 381 | `id_cons` int(11) NOT NULL DEFAULT 0,
|
---|
[270] | 382 | `mid` int(7) NOT NULL,
|
---|
[394] | 383 | `title` varchar(150) NOT NULL DEFAULT ' ',
|
---|
| 384 | `preamble` text DEFAULT NULL,
|
---|
| 385 | `content` text DEFAULT NULL,
|
---|
| 386 | `editimage` varchar(100) NOT NULL DEFAULT ' '
|
---|
| 387 | ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;
|
---|
[2] | 388 |
|
---|
[270] | 389 | CREATE TABLE `soraldo_ele_sezioni` (
|
---|
[360] | 390 | `id_cons` int(11) NOT NULL DEFAULT 0,
|
---|
[270] | 391 | `id_sez` int(11) NOT NULL,
|
---|
[360] | 392 | `id_sede` int(11) NOT NULL DEFAULT 0,
|
---|
| 393 | `num_sez` int(7) NOT NULL DEFAULT 0,
|
---|
[270] | 394 | `maschi` int(4) DEFAULT NULL,
|
---|
| 395 | `femmine` int(4) DEFAULT NULL,
|
---|
[360] | 396 | `validi` int(7) NOT NULL DEFAULT 0,
|
---|
| 397 | `nulli` int(7) NOT NULL DEFAULT 0,
|
---|
| 398 | `bianchi` int(7) NOT NULL DEFAULT 0,
|
---|
| 399 | `contestati` int(7) NOT NULL DEFAULT 0,
|
---|
| 400 | `solo_gruppo` int(7) NOT NULL DEFAULT 0,
|
---|
| 401 | `autorizzati_m` int(4) NOT NULL DEFAULT 0,
|
---|
| 402 | `autorizzati_f` int(4) NOT NULL DEFAULT 0,
|
---|
| 403 | `voti_nulli` int(7) NOT NULL DEFAULT 0,
|
---|
| 404 | `validi_lista` int(7) NOT NULL DEFAULT 0,
|
---|
| 405 | `contestati_lista` int(7) NOT NULL DEFAULT 0,
|
---|
| 406 | `voti_nulli_lista` int(7) NOT NULL DEFAULT 0,
|
---|
| 407 | `solo_lista` int(7) NOT NULL DEFAULT 0,
|
---|
[394] | 408 | `colore` varchar(50) DEFAULT '#FAFAD2'
|
---|
| 409 | ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;
|
---|
[2] | 410 |
|
---|
[270] | 411 | CREATE TABLE `soraldo_ele_temi` (
|
---|
| 412 | `id` int(11) NOT NULL,
|
---|
| 413 | `tema` varchar(20) NOT NULL DEFAULT ''
|
---|
[394] | 414 | ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;
|
---|
[2] | 415 |
|
---|
[270] | 416 | CREATE TABLE `soraldo_ele_tipo` (
|
---|
[360] | 417 | `tipo_cons` int(11) NOT NULL DEFAULT 0,
|
---|
[270] | 418 | `descrizione` varchar(30) DEFAULT NULL,
|
---|
| 419 | `lingua` varchar(2) NOT NULL DEFAULT '0',
|
---|
[360] | 420 | `genere` tinyint(4) NOT NULL DEFAULT 0,
|
---|
[270] | 421 | `voto_g` enum('0','1') NOT NULL DEFAULT '0',
|
---|
| 422 | `voto_l` enum('0','1') NOT NULL DEFAULT '0',
|
---|
| 423 | `voto_c` enum('0','1') NOT NULL DEFAULT '0',
|
---|
| 424 | `circo` enum('0','1') NOT NULL DEFAULT '0'
|
---|
[394] | 425 | ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;
|
---|
[2] | 426 |
|
---|
[270] | 427 | INSERT INTO `soraldo_ele_tipo` (`tipo_cons`, `descrizione`, `lingua`, `genere`, `voto_g`, `voto_l`, `voto_c`, `circo`) VALUES
|
---|
| 428 | (1, 'PROVINCIALI', 'it', 3, '0', '0', '0', '0'),
|
---|
| 429 | (2, 'REFERENDUM', 'it', 0, '0', '0', '0', '0'),
|
---|
| 430 | (3, 'COMUNALI', 'it', 5, '0', '0', '0', '0'),
|
---|
| 431 | (4, 'CIRCOSCRIZIONALI', 'it', 5, '0', '0', '0', '1'),
|
---|
| 432 | (5, 'BALLOTTAGGIO COMUNALI', 'it', 1, '0', '0', '0', '0'),
|
---|
| 433 | (6, 'CAMERA', 'it', 2, '0', '0', '0', '0'),
|
---|
| 434 | (7, 'SENATO', 'it', 2, '0', '0', '0', '0'),
|
---|
[354] | 435 | (8, 'EUROPEE', 'it', 4, '0', '0', '0', '0'),
|
---|
[270] | 436 | (9, 'REGIONALI', 'it', 5, '0', '0', '0', '0'),
|
---|
| 437 | (10, 'SENATO CON GRUPPI', 'it', 5, '1', '0', '1', '0'),
|
---|
| 438 | (11, 'CAMERA CON GRUPPI', 'it', 5, '1', '0', '1', '0'),
|
---|
| 439 | (12, 'PROVINCIALI CON COLLEGI', 'it', 3, '0', '0', '0', '1'),
|
---|
| 440 | (13, 'BALLOTTAGGIO PROVINCIALI', 'it', 1, '0', '0', '0', '0'),
|
---|
| 441 | (14, 'EUROPEE CON COLLEGI', 'it', 4, '0', '0', '0', '1'),
|
---|
| 442 | (15, 'CAMERA CON GRUPPI E COLLEGI', 'it', 5, '1', '0', '1', '1'),
|
---|
| 443 | (16, 'SENATO CON GRUPPI E COLLEGI', 'it', 5, '1', '0', '1', '1'),
|
---|
| 444 | (17, 'REGIONALI CON COLLEGI', 'it', 5, '0', '0', '0', '1'),
|
---|
| 445 | (18, 'CAMERA - Rosatellum 2.0', 'it', 5, '0', '0', '1', '0'),
|
---|
| 446 | (19, 'SENATO - Rosatellum 2.0', 'it', 5, '0', '0', '1', '0');
|
---|
| 447 |
|
---|
| 448 | CREATE TABLE `soraldo_ele_voti_candidati` (
|
---|
[360] | 449 | `id_cons` int(11) NOT NULL DEFAULT 0,
|
---|
| 450 | `id_cand` int(11) NOT NULL DEFAULT 0,
|
---|
| 451 | `id_sez` int(11) NOT NULL DEFAULT 0,
|
---|
[270] | 452 | `num_cand` int(2) UNSIGNED NOT NULL,
|
---|
[360] | 453 | `voti` int(7) NOT NULL DEFAULT 0
|
---|
[394] | 454 | ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;
|
---|
[2] | 455 |
|
---|
[270] | 456 | CREATE TABLE `soraldo_ele_voti_gruppo` (
|
---|
[360] | 457 | `id_cons` int(11) NOT NULL DEFAULT 0,
|
---|
| 458 | `id_gruppo` int(11) NOT NULL DEFAULT 0,
|
---|
| 459 | `id_sez` int(11) NOT NULL DEFAULT 0,
|
---|
[270] | 460 | `num_gruppo` int(2) UNSIGNED NOT NULL,
|
---|
[360] | 461 | `voti` int(7) NOT NULL DEFAULT 0,
|
---|
| 462 | `solo_gruppo` int(7) NOT NULL DEFAULT 0
|
---|
[394] | 463 | ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;
|
---|
[2] | 464 |
|
---|
[270] | 465 | CREATE TABLE `soraldo_ele_voti_lista` (
|
---|
[360] | 466 | `id_cons` int(11) NOT NULL DEFAULT 0,
|
---|
| 467 | `id_lista` int(11) NOT NULL DEFAULT 0,
|
---|
| 468 | `id_sez` int(11) NOT NULL DEFAULT 0,
|
---|
| 469 | `num_lista` int(2) UNSIGNED DEFAULT 0,
|
---|
| 470 | `voti` int(7) NOT NULL DEFAULT 0,
|
---|
| 471 | `nulli_lista` int(7) NOT NULL DEFAULT 0,
|
---|
| 472 | `solo_lista` int(7) DEFAULT 0
|
---|
[394] | 473 | ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;
|
---|
[2] | 474 |
|
---|
[270] | 475 | CREATE TABLE `soraldo_ele_voti_parziale` (
|
---|
[360] | 476 | `id_cons` int(11) NOT NULL DEFAULT 0,
|
---|
| 477 | `id_sez` int(11) NOT NULL DEFAULT 0,
|
---|
[270] | 478 | `id_parz` int(11) NOT NULL,
|
---|
| 479 | `orario` time NOT NULL DEFAULT '00:00:00',
|
---|
[394] | 480 | `data` date NOT NULL DEFAULT '1900-01-01',
|
---|
[360] | 481 | `voti_uomini` int(7) NOT NULL DEFAULT 0,
|
---|
| 482 | `voti_donne` int(7) NOT NULL DEFAULT 0,
|
---|
| 483 | `voti_complessivi` int(7) NOT NULL DEFAULT 0,
|
---|
| 484 | `id_gruppo` int(11) NOT NULL DEFAULT 0
|
---|
[394] | 485 | ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;
|
---|
[2] | 486 |
|
---|
[270] | 487 | CREATE TABLE `soraldo_ele_voti_ref` (
|
---|
[360] | 488 | `id_cons` int(11) NOT NULL DEFAULT 0,
|
---|
| 489 | `id_gruppo` int(11) NOT NULL DEFAULT 0,
|
---|
| 490 | `id_sez` int(11) NOT NULL DEFAULT 0,
|
---|
[270] | 491 | `num_gruppo` int(2) UNSIGNED NOT NULL,
|
---|
[360] | 492 | `si` int(7) DEFAULT 0,
|
---|
| 493 | `no` int(7) DEFAULT 0,
|
---|
| 494 | `validi` int(7) DEFAULT 0,
|
---|
| 495 | `nulli` int(7) DEFAULT 0,
|
---|
| 496 | `bianchi` int(7) DEFAULT 0,
|
---|
| 497 | `contestati` int(7) DEFAULT 0
|
---|
[394] | 498 | ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;
|
---|
[2] | 499 |
|
---|
[270] | 500 | CREATE TABLE `soraldo_ele_widget` (
|
---|
| 501 | `id` int(10) NOT NULL,
|
---|
| 502 | `nome_file` varchar(255) NOT NULL DEFAULT '',
|
---|
| 503 | `titolo` varchar(255) NOT NULL DEFAULT '',
|
---|
[360] | 504 | `pos_or` int(1) NOT NULL DEFAULT 1,
|
---|
| 505 | `pos_ver` int(3) NOT NULL DEFAULT 0,
|
---|
| 506 | `attivo` int(1) NOT NULL DEFAULT 0
|
---|
[394] | 507 | ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci;
|
---|
[2] | 508 |
|
---|
[270] | 509 | INSERT INTO `soraldo_ele_widget` (`id`, `nome_file`, `titolo`, `pos_or`, `pos_ver`, `attivo`) VALUES
|
---|
| 510 | (1, '00_affluenze.php', '00_affluenze.php', 1, 0, 0),
|
---|
| 511 | (2, '01_votanti.php', '01_votanti.php', 1, 0, 0),
|
---|
| 512 | (3, '02_risultati.php', '02_risultati.php', 1, 0, 0),
|
---|
| 513 | (4, '04_sezioni.php', '04_sezioni.php', 1, 0, 0),
|
---|
[362] | 514 | (5, 'privacy.php', 'privacy.php', 1, 0, 0),
|
---|
[270] | 515 | (6, 'bloccocand.php', 'bloccocand.php', 1, 0, 0),
|
---|
| 516 | (7, 'bloccogen.php', 'bloccogen.php', 1, 0, 0),
|
---|
| 517 | (8, 'bloccolink.php', 'bloccolink.php', 1, 0, 0),
|
---|
| 518 | (9, 'bloccoref.php', 'bloccoref.php', 1, 0, 0),
|
---|
| 519 | (10, 'gom_affluenze.php', 'gom_affluenze.php', 1, 0, 0),
|
---|
[362] | 520 | (11, 'pie_affluenze.php', 'pie_affluenze.php', 1, 0, 0),
|
---|
| 521 | (12, 'social.php', 'social.php', 1, 0, 0),
|
---|
[413] | 522 | (13, 'cerca_candidato.php', 'cerca_candidato.php', 1, 0, 0);
|
---|
[270] | 523 |
|
---|
[2] | 524 |
|
---|
[270] | 525 | ALTER TABLE `soraldo_access`
|
---|
| 526 | ADD PRIMARY KEY (`access_id`);
|
---|
[2] | 527 |
|
---|
[270] | 528 | ALTER TABLE `soraldo_authors`
|
---|
| 529 | ADD PRIMARY KEY (`aid`,`id_comune`),
|
---|
| 530 | ADD KEY `aid` (`aid`);
|
---|
[2] | 531 |
|
---|
[270] | 532 | ALTER TABLE `soraldo_doc_cons`
|
---|
| 533 | ADD KEY `id_cons` (`id_cons`,`id_doc`);
|
---|
[2] | 534 |
|
---|
[270] | 535 | ALTER TABLE `soraldo_ele_candidati`
|
---|
[360] | 536 | ADD PRIMARY KEY (`id_cand`) USING BTREE,
|
---|
[270] | 537 | ADD KEY `id_lista` (`id_lista`),
|
---|
[360] | 538 | ADD KEY `id_cons` (`id_cons`,`id_lista`) USING BTREE;
|
---|
[2] | 539 |
|
---|
[270] | 540 | ALTER TABLE `soraldo_ele_circoscrizione`
|
---|
| 541 | ADD UNIQUE KEY `id_circ` (`id_circ`),
|
---|
| 542 | ADD UNIQUE KEY `id_cons` (`id_cons`,`num_circ`);
|
---|
[2] | 543 |
|
---|
[270] | 544 | ALTER TABLE `soraldo_ele_collegi`
|
---|
| 545 | ADD PRIMARY KEY (`id_collegio`),
|
---|
| 546 | ADD KEY `id_cons_gen` (`id_cons_gen`);
|
---|
[2] | 547 |
|
---|
[270] | 548 | ALTER TABLE `soraldo_ele_come`
|
---|
| 549 | ADD UNIQUE KEY `mid` (`mid`);
|
---|
[2] | 550 |
|
---|
[270] | 551 | ALTER TABLE `soraldo_ele_comuni`
|
---|
| 552 | ADD PRIMARY KEY (`id_comune`),
|
---|
| 553 | ADD KEY `access_id` (`descrizione`);
|
---|
[2] | 554 |
|
---|
[270] | 555 | ALTER TABLE `soraldo_ele_comu_collegi`
|
---|
| 556 | ADD PRIMARY KEY (`id_cons_gen`,`id_comune`),
|
---|
| 557 | ADD KEY `id_cons` (`id_cons`),
|
---|
| 558 | ADD KEY `id_collegio` (`id_collegio`);
|
---|
[2] | 559 |
|
---|
[270] | 560 | ALTER TABLE `soraldo_ele_conf`
|
---|
| 561 | ADD PRIMARY KEY (`id_conf`);
|
---|
[2] | 562 |
|
---|
[270] | 563 | ALTER TABLE `soraldo_ele_consultazione`
|
---|
[360] | 564 | ADD PRIMARY KEY (`id_cons_gen`),
|
---|
| 565 | ADD UNIQUE KEY `descrizione` (`descrizione`(100));
|
---|
[2] | 566 |
|
---|
[270] | 567 | ALTER TABLE `soraldo_ele_cons_comune`
|
---|
| 568 | ADD PRIMARY KEY (`id_cons`),
|
---|
| 569 | ADD UNIQUE KEY `comune` (`id_comune`,`id_cons_gen`);
|
---|
[2] | 570 |
|
---|
[270] | 571 | ALTER TABLE `soraldo_ele_controlli`
|
---|
| 572 | ADD KEY `sezione` (`id_sez`);
|
---|
[2] | 573 |
|
---|
[270] | 574 | ALTER TABLE `soraldo_ele_documenti`
|
---|
| 575 | ADD PRIMARY KEY (`id_doc`),
|
---|
| 576 | ADD KEY `descrizione` (`descrizione`);
|
---|
[2] | 577 |
|
---|
[270] | 578 | ALTER TABLE `soraldo_ele_fasce`
|
---|
| 579 | ADD KEY `id_fascia` (`id_fascia`);
|
---|
[2] | 580 |
|
---|
[270] | 581 | ALTER TABLE `soraldo_ele_gruppo`
|
---|
[360] | 582 | ADD PRIMARY KEY (`id_gruppo`) USING BTREE,
|
---|
| 583 | ADD KEY `id_cons` (`id_cons`,`id_circ`) USING BTREE;
|
---|
[2] | 584 |
|
---|
[270] | 585 | ALTER TABLE `soraldo_ele_link`
|
---|
| 586 | ADD PRIMARY KEY (`mid`);
|
---|
[2] | 587 |
|
---|
[270] | 588 | ALTER TABLE `soraldo_ele_lista`
|
---|
[360] | 589 | ADD PRIMARY KEY (`id_lista`) USING BTREE,
|
---|
| 590 | ADD KEY `id_gruppo` (`id_gruppo`),
|
---|
| 591 | ADD KEY `id_cons` (`id_cons`,`id_gruppo`) USING BTREE;
|
---|
[2] | 592 |
|
---|
[270] | 593 | ALTER TABLE `soraldo_ele_modelli`
|
---|
| 594 | ADD KEY `access_id` (`id_cons`);
|
---|
[93] | 595 |
|
---|
[270] | 596 | ALTER TABLE `soraldo_ele_numeri`
|
---|
| 597 | ADD PRIMARY KEY (`mid`),
|
---|
| 598 | ADD KEY `id_cons` (`id_cons`);
|
---|
[93] | 599 |
|
---|
[270] | 600 | ALTER TABLE `soraldo_ele_operatori`
|
---|
| 601 | ADD UNIQUE KEY `id_cons_aid` (`id_cons`,`aid`,`id_comune`),
|
---|
| 602 | ADD KEY `id_circ` (`id_comune`),
|
---|
| 603 | ADD KEY `id_sede` (`id_sede`);
|
---|
[93] | 604 |
|
---|
[270] | 605 | ALTER TABLE `soraldo_ele_regioni`
|
---|
| 606 | ADD PRIMARY KEY (`id`),
|
---|
| 607 | ADD KEY `descrizione` (`descrizione`);
|
---|
[2] | 608 |
|
---|
[270] | 609 | ALTER TABLE `soraldo_ele_rilaff`
|
---|
| 610 | ADD KEY `id_cons_gen` (`id_cons_gen`);
|
---|
[2] | 611 |
|
---|
[270] | 612 | ALTER TABLE `soraldo_ele_sede`
|
---|
| 613 | ADD PRIMARY KEY (`id_sede`),
|
---|
| 614 | ADD KEY `id_cons` (`id_cons`),
|
---|
| 615 | ADD KEY `id_circ` (`id_circ`);
|
---|
[2] | 616 |
|
---|
[270] | 617 | ALTER TABLE `soraldo_ele_servizi`
|
---|
| 618 | ADD PRIMARY KEY (`mid`),
|
---|
| 619 | ADD KEY `id_cons` (`id_cons`);
|
---|
[2] | 620 |
|
---|
[270] | 621 | ALTER TABLE `soraldo_ele_sezioni`
|
---|
| 622 | ADD UNIQUE KEY `id_sezi` (`id_sez`),
|
---|
[394] | 623 | ADD UNIQUE KEY `id_cons` (`id_cons`,`num_sez`) USING BTREE,
|
---|
[270] | 624 | ADD KEY `id_sede` (`id_sede`);
|
---|
[2] | 625 |
|
---|
[270] | 626 | ALTER TABLE `soraldo_ele_temi`
|
---|
| 627 | ADD PRIMARY KEY (`id`);
|
---|
[2] | 628 |
|
---|
[270] | 629 | ALTER TABLE `soraldo_ele_tipo`
|
---|
| 630 | ADD PRIMARY KEY (`tipo_cons`);
|
---|
[2] | 631 |
|
---|
[270] | 632 | ALTER TABLE `soraldo_ele_voti_candidati`
|
---|
| 633 | ADD KEY `id_sez` (`id_sez`),
|
---|
| 634 | ADD KEY `id_cand` (`id_cand`),
|
---|
[360] | 635 | ADD KEY `id_cons` (`id_cons`,`id_sez`,`id_cand`) USING BTREE;
|
---|
[2] | 636 |
|
---|
[270] | 637 | ALTER TABLE `soraldo_ele_voti_gruppo`
|
---|
| 638 | ADD KEY `id_gruppo` (`id_gruppo`),
|
---|
| 639 | ADD KEY `id_sez` (`id_sez`),
|
---|
[360] | 640 | ADD KEY `id_cons` (`id_cons`,`id_sez`,`id_gruppo`) USING BTREE;
|
---|
[2] | 641 |
|
---|
[270] | 642 | ALTER TABLE `soraldo_ele_voti_lista`
|
---|
| 643 | ADD KEY `id_lista` (`id_lista`),
|
---|
| 644 | ADD KEY `id_sez` (`id_sez`),
|
---|
[360] | 645 | ADD KEY `id_cons` (`id_cons`,`id_sez`,`id_lista`) USING BTREE;
|
---|
[2] | 646 |
|
---|
[270] | 647 | ALTER TABLE `soraldo_ele_voti_parziale`
|
---|
| 648 | ADD PRIMARY KEY (`id_parz`),
|
---|
| 649 | ADD KEY `id_cons` (`id_cons`),
|
---|
| 650 | ADD KEY `id_sez` (`id_sez`),
|
---|
| 651 | ADD KEY `id_gruppo` (`id_gruppo`);
|
---|
[2] | 652 |
|
---|
[270] | 653 | ALTER TABLE `soraldo_ele_voti_ref`
|
---|
| 654 | ADD KEY `id_gruppo` (`id_gruppo`),
|
---|
| 655 | ADD KEY `id_sez` (`id_sez`),
|
---|
[360] | 656 | ADD KEY `id_cons` (`id_cons`,`id_gruppo`) USING BTREE;
|
---|
[2] | 657 |
|
---|
[270] | 658 | ALTER TABLE `soraldo_ele_widget`
|
---|
| 659 | ADD PRIMARY KEY (`id`);
|
---|
[2] | 660 |
|
---|
| 661 |
|
---|
[270] | 662 | ALTER TABLE `soraldo_ele_candidati`
|
---|
| 663 | MODIFY `id_cand` int(11) NOT NULL AUTO_INCREMENT;
|
---|
[2] | 664 |
|
---|
[270] | 665 | ALTER TABLE `soraldo_ele_circoscrizione`
|
---|
| 666 | MODIFY `id_circ` int(11) NOT NULL AUTO_INCREMENT;
|
---|
[2] | 667 |
|
---|
[270] | 668 | ALTER TABLE `soraldo_ele_collegi`
|
---|
| 669 | MODIFY `id_collegio` int(11) NOT NULL AUTO_INCREMENT;
|
---|
[2] | 670 |
|
---|
[270] | 671 | ALTER TABLE `soraldo_ele_come`
|
---|
| 672 | MODIFY `mid` int(7) NOT NULL AUTO_INCREMENT;
|
---|
[2] | 673 |
|
---|
[270] | 674 | ALTER TABLE `soraldo_ele_conf`
|
---|
| 675 | MODIFY `id_conf` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=8;
|
---|
[2] | 676 |
|
---|
[270] | 677 | ALTER TABLE `soraldo_ele_consultazione`
|
---|
| 678 | MODIFY `id_cons_gen` int(11) NOT NULL AUTO_INCREMENT;
|
---|
[2] | 679 |
|
---|
[270] | 680 | ALTER TABLE `soraldo_ele_cons_comune`
|
---|
| 681 | MODIFY `id_cons` int(11) NOT NULL AUTO_INCREMENT;
|
---|
[2] | 682 |
|
---|
[270] | 683 | ALTER TABLE `soraldo_ele_documenti`
|
---|
| 684 | MODIFY `id_doc` int(11) NOT NULL AUTO_INCREMENT;
|
---|
[2] | 685 |
|
---|
[270] | 686 | ALTER TABLE `soraldo_ele_gruppo`
|
---|
| 687 | MODIFY `id_gruppo` int(11) NOT NULL AUTO_INCREMENT;
|
---|
[2] | 688 |
|
---|
[270] | 689 | ALTER TABLE `soraldo_ele_link`
|
---|
| 690 | MODIFY `mid` int(7) NOT NULL AUTO_INCREMENT;
|
---|
[2] | 691 |
|
---|
[270] | 692 | ALTER TABLE `soraldo_ele_lista`
|
---|
| 693 | MODIFY `id_lista` int(11) NOT NULL AUTO_INCREMENT;
|
---|
[2] | 694 |
|
---|
[270] | 695 | ALTER TABLE `soraldo_ele_numeri`
|
---|
| 696 | MODIFY `mid` int(7) NOT NULL AUTO_INCREMENT;
|
---|
[77] | 697 |
|
---|
[270] | 698 | ALTER TABLE `soraldo_ele_sede`
|
---|
| 699 | MODIFY `id_sede` int(11) NOT NULL AUTO_INCREMENT;
|
---|
[77] | 700 |
|
---|
[270] | 701 | ALTER TABLE `soraldo_ele_servizi`
|
---|
| 702 | MODIFY `mid` int(7) NOT NULL AUTO_INCREMENT;
|
---|
[77] | 703 |
|
---|
[270] | 704 | ALTER TABLE `soraldo_ele_sezioni`
|
---|
| 705 | MODIFY `id_sez` int(11) NOT NULL AUTO_INCREMENT;
|
---|
[77] | 706 |
|
---|
[270] | 707 | ALTER TABLE `soraldo_ele_temi`
|
---|
| 708 | MODIFY `id` int(11) NOT NULL AUTO_INCREMENT;
|
---|
[77] | 709 |
|
---|
[270] | 710 | ALTER TABLE `soraldo_ele_voti_parziale`
|
---|
| 711 | MODIFY `id_parz` int(11) NOT NULL AUTO_INCREMENT;
|
---|
[77] | 712 |
|
---|
[270] | 713 | ALTER TABLE `soraldo_ele_widget`
|
---|
[394] | 714 | MODIFY `id` int(10) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=15;
|
---|
[270] | 715 | COMMIT;
|
---|
[77] | 716 |
|
---|
[270] | 717 | /*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
|
---|
| 718 | /*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
|
---|
| 719 | /*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
|
---|