SQL model – komentáře 14. díl
authorFrantišek Kučera <franta-hg@frantovo.cz>
Wed Jun 09 15:53:52 2010 +0200 (2010-06-09)
changeset 1375a7a24ac3a15
parent 136 230bd05dcfec
child 138 0ad2c44c29b8
SQL model – komentáře
sql/schéma.sql
     1.1 --- a/sql/schéma.sql	Wed Jun 09 15:51:41 2010 +0200
     1.2 +++ b/sql/schéma.sql	Wed Jun 09 15:53:52 2010 +0200
     1.3 @@ -2,7 +2,7 @@
     1.4  -- PostgreSQL database dump
     1.5  --
     1.6  
     1.7 --- Started on 2010-04-29 14:41:40 CEST
     1.8 +-- Started on 2010-06-09 15:52:26 CEST
     1.9  
    1.10  SET statement_timeout = 0;
    1.11  SET client_encoding = 'UTF8';
    1.12 @@ -36,7 +36,7 @@
    1.13  ALTER DOMAIN nekurak.email OWNER TO nekurak;
    1.14  
    1.15  --
    1.16 --- TOC entry 1914 (class 0 OID 0)
    1.17 +-- TOC entry 1926 (class 0 OID 0)
    1.18  -- Dependencies: 366
    1.19  -- Name: DOMAIN email; Type: COMMENT; Schema: nekurak; Owner: nekurak
    1.20  --
    1.21 @@ -46,7 +46,7 @@
    1.22  
    1.23  --
    1.24  -- TOC entry 65 (class 1255 OID 35124)
    1.25 --- Dependencies: 10 402
    1.26 +-- Dependencies: 10 406
    1.27  -- Name: bezny_uzivatel(); Type: FUNCTION; Schema: nekurak; Owner: nekurak
    1.28  --
    1.29  
    1.30 @@ -64,7 +64,7 @@
    1.31  ALTER FUNCTION nekurak.bezny_uzivatel() OWNER TO nekurak;
    1.32  
    1.33  --
    1.34 --- TOC entry 1915 (class 0 OID 0)
    1.35 +-- TOC entry 1927 (class 0 OID 0)
    1.36  -- Dependencies: 65
    1.37  -- Name: FUNCTION bezny_uzivatel(); Type: COMMENT; Schema: nekurak; Owner: nekurak
    1.38  --
    1.39 @@ -73,7 +73,7 @@
    1.40  
    1.41  
    1.42  --
    1.43 --- TOC entry 1601 (class 1259 OID 35223)
    1.44 +-- TOC entry 1605 (class 1259 OID 35223)
    1.45  -- Dependencies: 10
    1.46  -- Name: clanek_seq; Type: SEQUENCE; Schema: nekurak; Owner: nekurak
    1.47  --
    1.48 @@ -92,8 +92,8 @@
    1.49  SET default_with_oids = false;
    1.50  
    1.51  --
    1.52 --- TOC entry 1600 (class 1259 OID 35205)
    1.53 --- Dependencies: 1882 10
    1.54 +-- TOC entry 1604 (class 1259 OID 35205)
    1.55 +-- Dependencies: 1888 10
    1.56  -- Name: clanek; Type: TABLE; Schema: nekurak; Owner: nekurak; Tablespace: 
    1.57  --
    1.58  
    1.59 @@ -107,8 +107,8 @@
    1.60  ALTER TABLE nekurak.clanek OWNER TO nekurak;
    1.61  
    1.62  --
    1.63 --- TOC entry 1917 (class 0 OID 0)
    1.64 --- Dependencies: 1600
    1.65 +-- TOC entry 1929 (class 0 OID 0)
    1.66 +-- Dependencies: 1604
    1.67  -- Name: TABLE clanek; Type: COMMENT; Schema: nekurak; Owner: nekurak
    1.68  --
    1.69  
    1.70 @@ -116,7 +116,7 @@
    1.71  
    1.72  
    1.73  --
    1.74 --- TOC entry 1598 (class 1259 OID 35183)
    1.75 +-- TOC entry 1602 (class 1259 OID 35183)
    1.76  -- Dependencies: 10
    1.77  -- Name: fotka_seq; Type: SEQUENCE; Schema: nekurak; Owner: nekurak
    1.78  --
    1.79 @@ -132,8 +132,8 @@
    1.80  ALTER TABLE nekurak.fotka_seq OWNER TO nekurak;
    1.81  
    1.82  --
    1.83 --- TOC entry 1599 (class 1259 OID 35185)
    1.84 --- Dependencies: 1880 1881 10
    1.85 +-- TOC entry 1603 (class 1259 OID 35185)
    1.86 +-- Dependencies: 1886 1887 10
    1.87  -- Name: fotka; Type: TABLE; Schema: nekurak; Owner: nekurak; Tablespace: 
    1.88  --
    1.89  
    1.90 @@ -148,8 +148,8 @@
    1.91  ALTER TABLE nekurak.fotka OWNER TO nekurak;
    1.92  
    1.93  --
    1.94 --- TOC entry 1920 (class 0 OID 0)
    1.95 --- Dependencies: 1599
    1.96 +-- TOC entry 1932 (class 0 OID 0)
    1.97 +-- Dependencies: 1603
    1.98  -- Name: TABLE fotka; Type: COMMENT; Schema: nekurak; Owner: nekurak
    1.99  --
   1.100  
   1.101 @@ -157,8 +157,8 @@
   1.102  
   1.103  
   1.104  --
   1.105 --- TOC entry 1921 (class 0 OID 0)
   1.106 --- Dependencies: 1599
   1.107 +-- TOC entry 1933 (class 0 OID 0)
   1.108 +-- Dependencies: 1603
   1.109  -- Name: COLUMN fotka.poradi; Type: COMMENT; Schema: nekurak; Owner: nekurak
   1.110  --
   1.111  
   1.112 @@ -166,7 +166,7 @@
   1.113  
   1.114  
   1.115  --
   1.116 --- TOC entry 1603 (class 1259 OID 35250)
   1.117 +-- TOC entry 1607 (class 1259 OID 35250)
   1.118  -- Dependencies: 10
   1.119  -- Name: hlasovani_seq; Type: SEQUENCE; Schema: nekurak; Owner: nekurak
   1.120  --
   1.121 @@ -181,8 +181,8 @@
   1.122  ALTER TABLE nekurak.hlasovani_seq OWNER TO nekurak;
   1.123  
   1.124  --
   1.125 --- TOC entry 1604 (class 1259 OID 35278)
   1.126 --- Dependencies: 1883 1884 10
   1.127 +-- TOC entry 1608 (class 1259 OID 35278)
   1.128 +-- Dependencies: 1889 1890 10
   1.129  -- Name: hlasovani; Type: TABLE; Schema: nekurak; Owner: nekurak; Tablespace: 
   1.130  --
   1.131  
   1.132 @@ -198,8 +198,8 @@
   1.133  ALTER TABLE nekurak.hlasovani OWNER TO nekurak;
   1.134  
   1.135  --
   1.136 --- TOC entry 1924 (class 0 OID 0)
   1.137 --- Dependencies: 1604
   1.138 +-- TOC entry 1936 (class 0 OID 0)
   1.139 +-- Dependencies: 1608
   1.140  -- Name: COLUMN hlasovani.id; Type: COMMENT; Schema: nekurak; Owner: nekurak
   1.141  --
   1.142  
   1.143 @@ -209,8 +209,8 @@
   1.144  
   1.145  
   1.146  --
   1.147 --- TOC entry 1925 (class 0 OID 0)
   1.148 --- Dependencies: 1604
   1.149 +-- TOC entry 1937 (class 0 OID 0)
   1.150 +-- Dependencies: 1608
   1.151  -- Name: COLUMN hlasovani.hlas; Type: COMMENT; Schema: nekurak; Owner: nekurak
   1.152  --
   1.153  
   1.154 @@ -220,7 +220,68 @@
   1.155  
   1.156  
   1.157  --
   1.158 --- TOC entry 1592 (class 1259 OID 35019)
   1.159 +-- TOC entry 1609 (class 1259 OID 35333)
   1.160 +-- Dependencies: 10
   1.161 +-- Name: komentar_seq; Type: SEQUENCE; Schema: nekurak; Owner: nekurak
   1.162 +--
   1.163 +
   1.164 +CREATE SEQUENCE komentar_seq
   1.165 +    INCREMENT BY 1
   1.166 +    NO MAXVALUE
   1.167 +    NO MINVALUE
   1.168 +    CACHE 1;
   1.169 +
   1.170 +
   1.171 +ALTER TABLE nekurak.komentar_seq OWNER TO nekurak;
   1.172 +
   1.173 +--
   1.174 +-- TOC entry 1610 (class 1259 OID 35376)
   1.175 +-- Dependencies: 1891 1892 10
   1.176 +-- Name: komentar; Type: TABLE; Schema: nekurak; Owner: nekurak; Tablespace: 
   1.177 +--
   1.178 +
   1.179 +CREATE TABLE komentar (
   1.180 +    id integer DEFAULT nextval('komentar_seq'::regclass) NOT NULL,
   1.181 +    podnik integer NOT NULL,
   1.182 +    uzivatel character varying(64) NOT NULL,
   1.183 +    datum timestamp with time zone DEFAULT now() NOT NULL,
   1.184 +    nadpis character varying(255),
   1.185 +    komentar text NOT NULL
   1.186 +);
   1.187 +
   1.188 +
   1.189 +ALTER TABLE nekurak.komentar OWNER TO nekurak;
   1.190 +
   1.191 +--
   1.192 +-- TOC entry 1940 (class 0 OID 0)
   1.193 +-- Dependencies: 1610
   1.194 +-- Name: TABLE komentar; Type: COMMENT; Schema: nekurak; Owner: nekurak
   1.195 +--
   1.196 +
   1.197 +COMMENT ON TABLE komentar IS 'Komentář k podniku';
   1.198 +
   1.199 +
   1.200 +--
   1.201 +-- TOC entry 1941 (class 0 OID 0)
   1.202 +-- Dependencies: 1610
   1.203 +-- Name: COLUMN komentar.nadpis; Type: COMMENT; Schema: nekurak; Owner: nekurak
   1.204 +--
   1.205 +
   1.206 +COMMENT ON COLUMN komentar.nadpis IS 'vždy jen prostý text';
   1.207 +
   1.208 +
   1.209 +--
   1.210 +-- TOC entry 1942 (class 0 OID 0)
   1.211 +-- Dependencies: 1610
   1.212 +-- Name: COLUMN komentar.komentar; Type: COMMENT; Schema: nekurak; Owner: nekurak
   1.213 +--
   1.214 +
   1.215 +COMMENT ON COLUMN komentar.komentar IS 'Vlastní komentář. Vždy jen XHTML – převádíme na něj jak prostý text, tak Texy nebo cokoli jiného.
   1.216 +Jedná se o kus validního XML – má kořenový element <div/>';
   1.217 +
   1.218 +
   1.219 +--
   1.220 +-- TOC entry 1596 (class 1259 OID 35019)
   1.221  -- Dependencies: 10
   1.222  -- Name: podnik_seq; Type: SEQUENCE; Schema: nekurak; Owner: nekurak
   1.223  --
   1.224 @@ -235,8 +296,8 @@
   1.225  ALTER TABLE nekurak.podnik_seq OWNER TO nekurak;
   1.226  
   1.227  --
   1.228 --- TOC entry 1593 (class 1259 OID 35049)
   1.229 --- Dependencies: 1876 1877 10
   1.230 +-- TOC entry 1597 (class 1259 OID 35049)
   1.231 +-- Dependencies: 1882 1883 10
   1.232  -- Name: podnik; Type: TABLE; Schema: nekurak; Owner: nekurak; Tablespace: 
   1.233  --
   1.234  
   1.235 @@ -258,8 +319,8 @@
   1.236  ALTER TABLE nekurak.podnik OWNER TO nekurak;
   1.237  
   1.238  --
   1.239 --- TOC entry 1928 (class 0 OID 0)
   1.240 --- Dependencies: 1593
   1.241 +-- TOC entry 1945 (class 0 OID 0)
   1.242 +-- Dependencies: 1597
   1.243  -- Name: COLUMN podnik.spravce; Type: COMMENT; Schema: nekurak; Owner: nekurak
   1.244  --
   1.245  
   1.246 @@ -267,7 +328,7 @@
   1.247  
   1.248  
   1.249  --
   1.250 --- TOC entry 1596 (class 1259 OID 35101)
   1.251 +-- TOC entry 1600 (class 1259 OID 35101)
   1.252  -- Dependencies: 10
   1.253  -- Name: role; Type: TABLE; Schema: nekurak; Owner: nekurak; Tablespace: 
   1.254  --
   1.255 @@ -281,8 +342,8 @@
   1.256  ALTER TABLE nekurak.role OWNER TO nekurak;
   1.257  
   1.258  --
   1.259 --- TOC entry 1930 (class 0 OID 0)
   1.260 --- Dependencies: 1596
   1.261 +-- TOC entry 1947 (class 0 OID 0)
   1.262 +-- Dependencies: 1600
   1.263  -- Name: TABLE role; Type: COMMENT; Schema: nekurak; Owner: nekurak
   1.264  --
   1.265  
   1.266 @@ -290,7 +351,7 @@
   1.267  
   1.268  
   1.269  --
   1.270 --- TOC entry 1594 (class 1259 OID 35080)
   1.271 +-- TOC entry 1598 (class 1259 OID 35080)
   1.272  -- Dependencies: 10
   1.273  -- Name: uzivatel_seq; Type: SEQUENCE; Schema: nekurak; Owner: nekurak
   1.274  --
   1.275 @@ -305,8 +366,8 @@
   1.276  ALTER TABLE nekurak.uzivatel_seq OWNER TO nekurak;
   1.277  
   1.278  --
   1.279 --- TOC entry 1595 (class 1259 OID 35091)
   1.280 --- Dependencies: 1878 1879 10
   1.281 +-- TOC entry 1599 (class 1259 OID 35091)
   1.282 +-- Dependencies: 1884 1885 10
   1.283  -- Name: uzivatel; Type: TABLE; Schema: nekurak; Owner: nekurak; Tablespace: 
   1.284  --
   1.285  
   1.286 @@ -324,8 +385,8 @@
   1.287  ALTER TABLE nekurak.uzivatel OWNER TO nekurak;
   1.288  
   1.289  --
   1.290 --- TOC entry 1933 (class 0 OID 0)
   1.291 --- Dependencies: 1595
   1.292 +-- TOC entry 1950 (class 0 OID 0)
   1.293 +-- Dependencies: 1599
   1.294  -- Name: COLUMN uzivatel.prezdivka; Type: COMMENT; Schema: nekurak; Owner: nekurak
   1.295  --
   1.296  
   1.297 @@ -333,7 +394,7 @@
   1.298  
   1.299  
   1.300  --
   1.301 --- TOC entry 1597 (class 1259 OID 35106)
   1.302 +-- TOC entry 1601 (class 1259 OID 35106)
   1.303  -- Dependencies: 10
   1.304  -- Name: uzivatel_role; Type: TABLE; Schema: nekurak; Owner: nekurak; Tablespace: 
   1.305  --
   1.306 @@ -347,8 +408,8 @@
   1.307  ALTER TABLE nekurak.uzivatel_role OWNER TO nekurak;
   1.308  
   1.309  --
   1.310 --- TOC entry 1935 (class 0 OID 0)
   1.311 --- Dependencies: 1597
   1.312 +-- TOC entry 1952 (class 0 OID 0)
   1.313 +-- Dependencies: 1601
   1.314  -- Name: TABLE uzivatel_role; Type: COMMENT; Schema: nekurak; Owner: nekurak
   1.315  --
   1.316  
   1.317 @@ -356,8 +417,8 @@
   1.318  
   1.319  
   1.320  --
   1.321 --- TOC entry 1900 (class 2606 OID 35227)
   1.322 --- Dependencies: 1600 1600
   1.323 +-- TOC entry 1908 (class 2606 OID 35227)
   1.324 +-- Dependencies: 1604 1604
   1.325  -- Name: clanek_pk; Type: CONSTRAINT; Schema: nekurak; Owner: nekurak; Tablespace: 
   1.326  --
   1.327  
   1.328 @@ -366,8 +427,8 @@
   1.329  
   1.330  
   1.331  --
   1.332 --- TOC entry 1896 (class 2606 OID 35190)
   1.333 --- Dependencies: 1599 1599
   1.334 +-- TOC entry 1904 (class 2606 OID 35190)
   1.335 +-- Dependencies: 1603 1603
   1.336  -- Name: fotka_pk; Type: CONSTRAINT; Schema: nekurak; Owner: nekurak; Tablespace: 
   1.337  --
   1.338  
   1.339 @@ -376,8 +437,8 @@
   1.340  
   1.341  
   1.342  --
   1.343 --- TOC entry 1898 (class 2606 OID 35204)
   1.344 --- Dependencies: 1599 1599 1599
   1.345 +-- TOC entry 1906 (class 2606 OID 35204)
   1.346 +-- Dependencies: 1603 1603 1603
   1.347  -- Name: fotka_poradi_uq; Type: CONSTRAINT; Schema: nekurak; Owner: nekurak; Tablespace: 
   1.348  --
   1.349  
   1.350 @@ -386,8 +447,8 @@
   1.351  
   1.352  
   1.353  --
   1.354 --- TOC entry 1903 (class 2606 OID 35284)
   1.355 --- Dependencies: 1604 1604
   1.356 +-- TOC entry 1911 (class 2606 OID 35284)
   1.357 +-- Dependencies: 1608 1608
   1.358  -- Name: hlasovani_pk; Type: CONSTRAINT; Schema: nekurak; Owner: nekurak; Tablespace: 
   1.359  --
   1.360  
   1.361 @@ -396,8 +457,18 @@
   1.362  
   1.363  
   1.364  --
   1.365 --- TOC entry 1886 (class 2606 OID 35058)
   1.366 --- Dependencies: 1593 1593
   1.367 +-- TOC entry 1914 (class 2606 OID 35385)
   1.368 +-- Dependencies: 1610 1610
   1.369 +-- Name: komentar_pk; Type: CONSTRAINT; Schema: nekurak; Owner: nekurak; Tablespace: 
   1.370 +--
   1.371 +
   1.372 +ALTER TABLE ONLY komentar
   1.373 +    ADD CONSTRAINT komentar_pk PRIMARY KEY (id);
   1.374 +
   1.375 +
   1.376 +--
   1.377 +-- TOC entry 1894 (class 2606 OID 35058)
   1.378 +-- Dependencies: 1597 1597
   1.379  -- Name: podnik_pk; Type: CONSTRAINT; Schema: nekurak; Owner: nekurak; Tablespace: 
   1.380  --
   1.381  
   1.382 @@ -406,8 +477,8 @@
   1.383  
   1.384  
   1.385  --
   1.386 --- TOC entry 1892 (class 2606 OID 35105)
   1.387 --- Dependencies: 1596 1596
   1.388 +-- TOC entry 1900 (class 2606 OID 35105)
   1.389 +-- Dependencies: 1600 1600
   1.390  -- Name: skupina_pk; Type: CONSTRAINT; Schema: nekurak; Owner: nekurak; Tablespace: 
   1.391  --
   1.392  
   1.393 @@ -416,8 +487,8 @@
   1.394  
   1.395  
   1.396  --
   1.397 --- TOC entry 1888 (class 2606 OID 35098)
   1.398 --- Dependencies: 1595 1595
   1.399 +-- TOC entry 1896 (class 2606 OID 35098)
   1.400 +-- Dependencies: 1599 1599
   1.401  -- Name: uzivatel_pk; Type: CONSTRAINT; Schema: nekurak; Owner: nekurak; Tablespace: 
   1.402  --
   1.403  
   1.404 @@ -426,8 +497,8 @@
   1.405  
   1.406  
   1.407  --
   1.408 --- TOC entry 1890 (class 2606 OID 35100)
   1.409 --- Dependencies: 1595 1595
   1.410 +-- TOC entry 1898 (class 2606 OID 35100)
   1.411 +-- Dependencies: 1599 1599
   1.412  -- Name: uzivatel_prezdivka_uq; Type: CONSTRAINT; Schema: nekurak; Owner: nekurak; Tablespace: 
   1.413  --
   1.414  
   1.415 @@ -436,8 +507,8 @@
   1.416  
   1.417  
   1.418  --
   1.419 --- TOC entry 1894 (class 2606 OID 35137)
   1.420 --- Dependencies: 1597 1597 1597
   1.421 +-- TOC entry 1902 (class 2606 OID 35137)
   1.422 +-- Dependencies: 1601 1601 1601
   1.423  -- Name: uzivatel_role_pk; Type: CONSTRAINT; Schema: nekurak; Owner: nekurak; Tablespace: 
   1.424  --
   1.425  
   1.426 @@ -446,8 +517,8 @@
   1.427  
   1.428  
   1.429  --
   1.430 --- TOC entry 1901 (class 1259 OID 35291)
   1.431 --- Dependencies: 1604
   1.432 +-- TOC entry 1909 (class 1259 OID 35291)
   1.433 +-- Dependencies: 1608
   1.434  -- Name: hlasovani_ip_idx; Type: INDEX; Schema: nekurak; Owner: nekurak; Tablespace: 
   1.435  --
   1.436  
   1.437 @@ -455,8 +526,8 @@
   1.438  
   1.439  
   1.440  --
   1.441 --- TOC entry 1904 (class 1259 OID 35309)
   1.442 --- Dependencies: 1604
   1.443 +-- TOC entry 1912 (class 1259 OID 35309)
   1.444 +-- Dependencies: 1608
   1.445  -- Name: hlsovani_datum_idx; Type: INDEX; Schema: nekurak; Owner: nekurak; Tablespace: 
   1.446  --
   1.447  
   1.448 @@ -464,8 +535,8 @@
   1.449  
   1.450  
   1.451  --
   1.452 --- TOC entry 1910 (class 2620 OID 35125)
   1.453 --- Dependencies: 1595 65
   1.454 +-- TOC entry 1922 (class 2620 OID 35125)
   1.455 +-- Dependencies: 1599 65
   1.456  -- Name: uzivatel_insert; Type: TRIGGER; Schema: nekurak; Owner: nekurak
   1.457  --
   1.458  
   1.459 @@ -476,8 +547,8 @@
   1.460  
   1.461  
   1.462  --
   1.463 --- TOC entry 1908 (class 2606 OID 35191)
   1.464 --- Dependencies: 1599 1885 1593
   1.465 +-- TOC entry 1918 (class 2606 OID 35191)
   1.466 +-- Dependencies: 1893 1597 1603
   1.467  -- Name: fotka_podnik_fk; Type: FK CONSTRAINT; Schema: nekurak; Owner: nekurak
   1.468  --
   1.469  
   1.470 @@ -486,8 +557,8 @@
   1.471  
   1.472  
   1.473  --
   1.474 --- TOC entry 1909 (class 2606 OID 35285)
   1.475 --- Dependencies: 1885 1604 1593
   1.476 +-- TOC entry 1919 (class 2606 OID 35285)
   1.477 +-- Dependencies: 1597 1608 1893
   1.478  -- Name: hlasovani_podnik_fk; Type: FK CONSTRAINT; Schema: nekurak; Owner: nekurak
   1.479  --
   1.480  
   1.481 @@ -496,8 +567,28 @@
   1.482  
   1.483  
   1.484  --
   1.485 --- TOC entry 1905 (class 2606 OID 35178)
   1.486 --- Dependencies: 1889 1595 1593
   1.487 +-- TOC entry 1920 (class 2606 OID 35386)
   1.488 +-- Dependencies: 1610 1893 1597
   1.489 +-- Name: komentar_podnik_fk; Type: FK CONSTRAINT; Schema: nekurak; Owner: nekurak
   1.490 +--
   1.491 +
   1.492 +ALTER TABLE ONLY komentar
   1.493 +    ADD CONSTRAINT komentar_podnik_fk FOREIGN KEY (podnik) REFERENCES podnik(id);
   1.494 +
   1.495 +
   1.496 +--
   1.497 +-- TOC entry 1921 (class 2606 OID 35391)
   1.498 +-- Dependencies: 1599 1897 1610
   1.499 +-- Name: komentar_uzivatel_fk; Type: FK CONSTRAINT; Schema: nekurak; Owner: nekurak
   1.500 +--
   1.501 +
   1.502 +ALTER TABLE ONLY komentar
   1.503 +    ADD CONSTRAINT komentar_uzivatel_fk FOREIGN KEY (uzivatel) REFERENCES uzivatel(prezdivka);
   1.504 +
   1.505 +
   1.506 +--
   1.507 +-- TOC entry 1915 (class 2606 OID 35178)
   1.508 +-- Dependencies: 1599 1897 1597
   1.509  -- Name: podnik_uzivatel_fk; Type: FK CONSTRAINT; Schema: nekurak; Owner: nekurak
   1.510  --
   1.511  
   1.512 @@ -506,8 +597,8 @@
   1.513  
   1.514  
   1.515  --
   1.516 --- TOC entry 1906 (class 2606 OID 35138)
   1.517 --- Dependencies: 1597 1596 1891
   1.518 +-- TOC entry 1916 (class 2606 OID 35138)
   1.519 +-- Dependencies: 1600 1601 1899
   1.520  -- Name: uzivatel_role_role_fk; Type: FK CONSTRAINT; Schema: nekurak; Owner: nekurak
   1.521  --
   1.522  
   1.523 @@ -516,8 +607,8 @@
   1.524  
   1.525  
   1.526  --
   1.527 --- TOC entry 1907 (class 2606 OID 35143)
   1.528 --- Dependencies: 1597 1889 1595
   1.529 +-- TOC entry 1917 (class 2606 OID 35143)
   1.530 +-- Dependencies: 1599 1897 1601
   1.531  -- Name: uzivatel_role_uzivatel_fk; Type: FK CONSTRAINT; Schema: nekurak; Owner: nekurak
   1.532  --
   1.533  
   1.534 @@ -526,7 +617,7 @@
   1.535  
   1.536  
   1.537  --
   1.538 --- TOC entry 1913 (class 0 OID 0)
   1.539 +-- TOC entry 1925 (class 0 OID 0)
   1.540  -- Dependencies: 10
   1.541  -- Name: nekurak; Type: ACL; Schema: -; Owner: nekurak
   1.542  --
   1.543 @@ -538,8 +629,8 @@
   1.544  
   1.545  
   1.546  --
   1.547 --- TOC entry 1916 (class 0 OID 0)
   1.548 --- Dependencies: 1601
   1.549 +-- TOC entry 1928 (class 0 OID 0)
   1.550 +-- Dependencies: 1605
   1.551  -- Name: clanek_seq; Type: ACL; Schema: nekurak; Owner: nekurak
   1.552  --
   1.553  
   1.554 @@ -550,8 +641,8 @@
   1.555  
   1.556  
   1.557  --
   1.558 --- TOC entry 1918 (class 0 OID 0)
   1.559 --- Dependencies: 1600
   1.560 +-- TOC entry 1930 (class 0 OID 0)
   1.561 +-- Dependencies: 1604
   1.562  -- Name: clanek; Type: ACL; Schema: nekurak; Owner: nekurak
   1.563  --
   1.564  
   1.565 @@ -562,8 +653,8 @@
   1.566  
   1.567  
   1.568  --
   1.569 --- TOC entry 1919 (class 0 OID 0)
   1.570 --- Dependencies: 1598
   1.571 +-- TOC entry 1931 (class 0 OID 0)
   1.572 +-- Dependencies: 1602
   1.573  -- Name: fotka_seq; Type: ACL; Schema: nekurak; Owner: nekurak
   1.574  --
   1.575  
   1.576 @@ -574,8 +665,8 @@
   1.577  
   1.578  
   1.579  --
   1.580 --- TOC entry 1922 (class 0 OID 0)
   1.581 --- Dependencies: 1599
   1.582 +-- TOC entry 1934 (class 0 OID 0)
   1.583 +-- Dependencies: 1603
   1.584  -- Name: fotka; Type: ACL; Schema: nekurak; Owner: nekurak
   1.585  --
   1.586  
   1.587 @@ -586,8 +677,8 @@
   1.588  
   1.589  
   1.590  --
   1.591 --- TOC entry 1923 (class 0 OID 0)
   1.592 --- Dependencies: 1603
   1.593 +-- TOC entry 1935 (class 0 OID 0)
   1.594 +-- Dependencies: 1607
   1.595  -- Name: hlasovani_seq; Type: ACL; Schema: nekurak; Owner: nekurak
   1.596  --
   1.597  
   1.598 @@ -598,20 +689,44 @@
   1.599  
   1.600  
   1.601  --
   1.602 --- TOC entry 1926 (class 0 OID 0)
   1.603 --- Dependencies: 1604
   1.604 +-- TOC entry 1938 (class 0 OID 0)
   1.605 +-- Dependencies: 1608
   1.606  -- Name: hlasovani; Type: ACL; Schema: nekurak; Owner: nekurak
   1.607  --
   1.608  
   1.609  REVOKE ALL ON TABLE hlasovani FROM PUBLIC;
   1.610  REVOKE ALL ON TABLE hlasovani FROM nekurak;
   1.611  GRANT ALL ON TABLE hlasovani TO nekurak;
   1.612 -GRANT SELECT,INSERT,DELETE,UPDATE ON TABLE hlasovani TO nekurak_web;
   1.613 +GRANT SELECT,INSERT ON TABLE hlasovani TO nekurak_web;
   1.614  
   1.615  
   1.616  --
   1.617 --- TOC entry 1927 (class 0 OID 0)
   1.618 --- Dependencies: 1592
   1.619 +-- TOC entry 1939 (class 0 OID 0)
   1.620 +-- Dependencies: 1609
   1.621 +-- Name: komentar_seq; Type: ACL; Schema: nekurak; Owner: nekurak
   1.622 +--
   1.623 +
   1.624 +REVOKE ALL ON SEQUENCE komentar_seq FROM PUBLIC;
   1.625 +REVOKE ALL ON SEQUENCE komentar_seq FROM nekurak;
   1.626 +GRANT ALL ON SEQUENCE komentar_seq TO nekurak;
   1.627 +GRANT USAGE ON SEQUENCE komentar_seq TO nekurak_web;
   1.628 +
   1.629 +
   1.630 +--
   1.631 +-- TOC entry 1943 (class 0 OID 0)
   1.632 +-- Dependencies: 1610
   1.633 +-- Name: komentar; Type: ACL; Schema: nekurak; Owner: nekurak
   1.634 +--
   1.635 +
   1.636 +REVOKE ALL ON TABLE komentar FROM PUBLIC;
   1.637 +REVOKE ALL ON TABLE komentar FROM nekurak;
   1.638 +GRANT ALL ON TABLE komentar TO nekurak;
   1.639 +GRANT SELECT,INSERT ON TABLE komentar TO nekurak_web;
   1.640 +
   1.641 +
   1.642 +--
   1.643 +-- TOC entry 1944 (class 0 OID 0)
   1.644 +-- Dependencies: 1596
   1.645  -- Name: podnik_seq; Type: ACL; Schema: nekurak; Owner: nekurak
   1.646  --
   1.647  
   1.648 @@ -622,8 +737,8 @@
   1.649  
   1.650  
   1.651  --
   1.652 --- TOC entry 1929 (class 0 OID 0)
   1.653 --- Dependencies: 1593
   1.654 +-- TOC entry 1946 (class 0 OID 0)
   1.655 +-- Dependencies: 1597
   1.656  -- Name: podnik; Type: ACL; Schema: nekurak; Owner: nekurak
   1.657  --
   1.658  
   1.659 @@ -634,8 +749,8 @@
   1.660  
   1.661  
   1.662  --
   1.663 --- TOC entry 1931 (class 0 OID 0)
   1.664 --- Dependencies: 1596
   1.665 +-- TOC entry 1948 (class 0 OID 0)
   1.666 +-- Dependencies: 1600
   1.667  -- Name: role; Type: ACL; Schema: nekurak; Owner: nekurak
   1.668  --
   1.669  
   1.670 @@ -646,8 +761,8 @@
   1.671  
   1.672  
   1.673  --
   1.674 --- TOC entry 1932 (class 0 OID 0)
   1.675 --- Dependencies: 1594
   1.676 +-- TOC entry 1949 (class 0 OID 0)
   1.677 +-- Dependencies: 1598
   1.678  -- Name: uzivatel_seq; Type: ACL; Schema: nekurak; Owner: nekurak
   1.679  --
   1.680  
   1.681 @@ -658,8 +773,8 @@
   1.682  
   1.683  
   1.684  --
   1.685 --- TOC entry 1934 (class 0 OID 0)
   1.686 --- Dependencies: 1595
   1.687 +-- TOC entry 1951 (class 0 OID 0)
   1.688 +-- Dependencies: 1599
   1.689  -- Name: uzivatel; Type: ACL; Schema: nekurak; Owner: nekurak
   1.690  --
   1.691  
   1.692 @@ -670,8 +785,8 @@
   1.693  
   1.694  
   1.695  --
   1.696 --- TOC entry 1936 (class 0 OID 0)
   1.697 --- Dependencies: 1597
   1.698 +-- TOC entry 1953 (class 0 OID 0)
   1.699 +-- Dependencies: 1601
   1.700  -- Name: uzivatel_role; Type: ACL; Schema: nekurak; Owner: nekurak
   1.701  --
   1.702  
   1.703 @@ -681,7 +796,7 @@
   1.704  GRANT SELECT,INSERT,DELETE,UPDATE ON TABLE uzivatel_role TO nekurak_web;
   1.705  
   1.706  
   1.707 --- Completed on 2010-04-29 14:41:42 CEST
   1.708 +-- Completed on 2010-06-09 15:52:28 CEST
   1.709  
   1.710  --
   1.711  -- PostgreSQL database dump complete