source: trunk/sql/aggiornamento-2.0_2018-01-18.sql

Last change on this file was 268, checked in by roby, 6 years ago

Adeguamento del programma alla gestione del Rosatellum. Comprende un aggiornamento del db per l'inserimento dei nuovi tipi di consultazione per camera e senato.
Chi ha creato nuovi tipi personalizzati di consultazione non deve applicare la patch al db ma aggiungere autonomamente anche queste due tipologie.
Come sempre si consiglia di effettuare un backup del db prima di applicare la patch.

File size: 1.9 KB
Line 
1--
2-- Database: `eleonline`
3--
4
5
6DROP TABLE IF EXISTS `soraldo_ele_tipo`;
7-- --------------------------------------------------------
8
9--
10-- Struttura della tabella `soraldo_ele_tipo`
11--
12
13CREATE TABLE IF NOT EXISTS `soraldo_ele_tipo` (
14 `tipo_cons` int(11) NOT NULL DEFAULT '0',
15 `descrizione` varchar(30) DEFAULT NULL,
16 `lingua` varchar(2) NOT NULL DEFAULT '0',
17 `genere` tinyint(4) NOT NULL DEFAULT '0',
18 `voto_g` enum('0','1') NOT NULL DEFAULT '0',
19 `voto_l` enum('0','1') NOT NULL DEFAULT '0',
20 `voto_c` enum('0','1') NOT NULL DEFAULT '0',
21 `circo` enum('0','1') NOT NULL DEFAULT '0',
22 PRIMARY KEY (`tipo_cons`)
23) ENGINE=MyISAM DEFAULT CHARSET=latin1;
24
25--
26-- Dump dei dati per la tabella `soraldo_ele_tipo`
27--
28
29INSERT INTO `soraldo_ele_tipo` (`tipo_cons`, `descrizione`, `lingua`, `genere`, `voto_g`, `voto_l`, `voto_c`, `circo`) VALUES
30(1, 'PROVINCIALI', 'it', 3, '0', '0', '0', '0'),
31(2, 'REFERENDUM', 'it', 0, '0', '0', '0', '0'),
32(3, 'COMUNALI', 'it', 5, '0', '0', '0', '0'),
33(4, 'CIRCOSCRIZIONALI', 'it', 5, '0', '0', '0', '1'),
34(5, 'BALLOTTAGGIO COMUNALI', 'it', 1, '0', '0', '0', '0'),
35(6, 'CAMERA', 'it', 2, '0', '0', '0', '0'),
36(7, 'SENATO', 'it', 2, '0', '0', '0', '0'),
37(8, 'EUROPEE', 'it', 4, '1', '0', '0', '0'),
38(9, 'REGIONALI', 'it', 5, '0', '0', '0', '0'),
39(10, 'SENATO CON GRUPPI', 'it', 5, '1', '0', '1', '0'),
40(11, 'CAMERA CON GRUPPI', 'it', 5, '1', '0', '1', '0'),
41(12, 'PROVINCIALI CON COLLEGI', 'it', 3, '0', '0', '0', '1'),
42(13, 'BALLOTTAGGIO PROVINCIALI', 'it', 1, '0', '0', '0', '0'),
43(14, 'EUROPEE CON COLLEGI', 'it', 4, '0', '0', '0', '1'),
44(15, 'CAMERA CON GRUPPI E COLLEGI', 'it', 5, '1', '0', '1', '1'),
45(16, 'SENATO CON GRUPPI E COLLEGI', 'it', 5, '1', '0', '1', '1'),
46(17, 'REGIONALI CON COLLEGI', 'it', 5, '0', '0', '0', '1'),
47(18, 'CAMERA - Rosatellum 2.0', 'it', 5, '0', '0', '1', '0'),
48(19, 'SENATO - Rosatellum 2.0', 'it', 5, '0', '0', '1', '0');
49
50
Note: See TracBrowser for help on using the repository browser.