
diff -r 5f0d5e1305b3 -r bb8af29610c4 sql/schéma.sql
--- a/sql/schéma.sql	Tue Jan 11 15:27:51 2011 +0100
+++ b/sql/schéma.sql	Wed Jan 26 18:58:02 2011 +0100
@@ -2,7 +2,7 @@
 -- PostgreSQL database dump
 --
 
--- Started on 2011-01-11 15:26:21 CET
+-- Started on 2011-01-15 14:24:29 CET
 
 SET statement_timeout = 0;
 SET client_encoding = 'UTF8';
@@ -36,7 +36,7 @@
 ALTER DOMAIN nekurak.email OWNER TO nekurak;
 
 --
--- TOC entry 1942 (class 0 OID 0)
+-- TOC entry 1946 (class 0 OID 0)
 -- Dependencies: 366
 -- Name: DOMAIN email; Type: COMMENT; Schema: nekurak; Owner: nekurak
 --
@@ -46,7 +46,7 @@
 
 --
 -- TOC entry 65 (class 1255 OID 35124)
--- Dependencies: 411 10
+-- Dependencies: 412 10
 -- Name: bezny_uzivatel(); Type: FUNCTION; Schema: nekurak; Owner: nekurak
 --
 
@@ -64,7 +64,7 @@
 ALTER FUNCTION nekurak.bezny_uzivatel() OWNER TO nekurak;
 
 --
--- TOC entry 1943 (class 0 OID 0)
+-- TOC entry 1947 (class 0 OID 0)
 -- Dependencies: 65
 -- Name: FUNCTION bezny_uzivatel(); Type: COMMENT; Schema: nekurak; Owner: nekurak
 --
@@ -73,7 +73,7 @@
 
 
 --
--- TOC entry 1610 (class 1259 OID 35223)
+-- TOC entry 1611 (class 1259 OID 35223)
 -- Dependencies: 10
 -- Name: clanek_seq; Type: SEQUENCE; Schema: nekurak; Owner: nekurak
 --
@@ -92,8 +92,8 @@
 SET default_with_oids = false;
 
 --
--- TOC entry 1609 (class 1259 OID 35205)
--- Dependencies: 1897 10
+-- TOC entry 1610 (class 1259 OID 35205)
+-- Dependencies: 1899 10
 -- Name: clanek; Type: TABLE; Schema: nekurak; Owner: nekurak; Tablespace: 
 --
 
@@ -107,8 +107,8 @@
 ALTER TABLE nekurak.clanek OWNER TO nekurak;
 
 --
--- TOC entry 1945 (class 0 OID 0)
--- Dependencies: 1609
+-- TOC entry 1949 (class 0 OID 0)
+-- Dependencies: 1610
 -- Name: TABLE clanek; Type: COMMENT; Schema: nekurak; Owner: nekurak
 --
 
@@ -116,7 +116,7 @@
 
 
 --
--- TOC entry 1607 (class 1259 OID 35183)
+-- TOC entry 1608 (class 1259 OID 35183)
 -- Dependencies: 10
 -- Name: fotka_seq; Type: SEQUENCE; Schema: nekurak; Owner: nekurak
 --
@@ -132,8 +132,8 @@
 ALTER TABLE nekurak.fotka_seq OWNER TO nekurak;
 
 --
--- TOC entry 1608 (class 1259 OID 35185)
--- Dependencies: 1895 1896 10
+-- TOC entry 1609 (class 1259 OID 35185)
+-- Dependencies: 1897 1898 10
 -- Name: fotka; Type: TABLE; Schema: nekurak; Owner: nekurak; Tablespace: 
 --
 
@@ -148,8 +148,8 @@
 ALTER TABLE nekurak.fotka OWNER TO nekurak;
 
 --
--- TOC entry 1948 (class 0 OID 0)
--- Dependencies: 1608
+-- TOC entry 1952 (class 0 OID 0)
+-- Dependencies: 1609
 -- Name: TABLE fotka; Type: COMMENT; Schema: nekurak; Owner: nekurak
 --
 
@@ -157,8 +157,8 @@
 
 
 --
--- TOC entry 1949 (class 0 OID 0)
--- Dependencies: 1608
+-- TOC entry 1953 (class 0 OID 0)
+-- Dependencies: 1609
 -- Name: COLUMN fotka.poradi; Type: COMMENT; Schema: nekurak; Owner: nekurak
 --
 
@@ -166,7 +166,7 @@
 
 
 --
--- TOC entry 1612 (class 1259 OID 35250)
+-- TOC entry 1613 (class 1259 OID 35250)
 -- Dependencies: 10
 -- Name: hlasovani_seq; Type: SEQUENCE; Schema: nekurak; Owner: nekurak
 --
@@ -181,8 +181,8 @@
 ALTER TABLE nekurak.hlasovani_seq OWNER TO nekurak;
 
 --
--- TOC entry 1613 (class 1259 OID 35278)
--- Dependencies: 1898 1899 10
+-- TOC entry 1614 (class 1259 OID 35278)
+-- Dependencies: 1900 1901 10
 -- Name: hlasovani; Type: TABLE; Schema: nekurak; Owner: nekurak; Tablespace: 
 --
 
@@ -198,8 +198,8 @@
 ALTER TABLE nekurak.hlasovani OWNER TO nekurak;
 
 --
--- TOC entry 1952 (class 0 OID 0)
--- Dependencies: 1613
+-- TOC entry 1956 (class 0 OID 0)
+-- Dependencies: 1614
 -- Name: COLUMN hlasovani.id; Type: COMMENT; Schema: nekurak; Owner: nekurak
 --
 
@@ -209,8 +209,8 @@
 
 
 --
--- TOC entry 1953 (class 0 OID 0)
--- Dependencies: 1613
+-- TOC entry 1957 (class 0 OID 0)
+-- Dependencies: 1614
 -- Name: COLUMN hlasovani.hlas; Type: COMMENT; Schema: nekurak; Owner: nekurak
 --
 
@@ -220,28 +220,13 @@
 
 
 --
--- TOC entry 1616 (class 1259 OID 35396)
+-- TOC entry 1617 (class 1259 OID 35398)
 -- Dependencies: 10
--- Name: kategorie_seq; Type: SEQUENCE; Schema: nekurak; Owner: nekurak
---
-
-CREATE SEQUENCE kategorie_seq
-    INCREMENT BY 1
-    NO MAXVALUE
-    NO MINVALUE
-    CACHE 1;
-
-
-ALTER TABLE nekurak.kategorie_seq OWNER TO nekurak;
-
---
--- TOC entry 1617 (class 1259 OID 35398)
--- Dependencies: 1902 10
 -- Name: kategorie; Type: TABLE; Schema: nekurak; Owner: nekurak; Tablespace: 
 --
 
 CREATE TABLE kategorie (
-    id integer DEFAULT nextval('kategorie_seq'::regclass) NOT NULL,
+    id integer NOT NULL,
     nazev character varying(32) NOT NULL
 );
 
@@ -249,7 +234,7 @@
 ALTER TABLE nekurak.kategorie OWNER TO nekurak;
 
 --
--- TOC entry 1956 (class 0 OID 0)
+-- TOC entry 1959 (class 0 OID 0)
 -- Dependencies: 1617
 -- Name: TABLE kategorie; Type: COMMENT; Schema: nekurak; Owner: nekurak
 --
@@ -258,7 +243,7 @@
 
 
 --
--- TOC entry 1957 (class 0 OID 0)
+-- TOC entry 1960 (class 0 OID 0)
 -- Dependencies: 1617
 -- Name: COLUMN kategorie.nazev; Type: COMMENT; Schema: nekurak; Owner: nekurak
 --
@@ -268,7 +253,7 @@
 
 
 --
--- TOC entry 1614 (class 1259 OID 35333)
+-- TOC entry 1615 (class 1259 OID 35333)
 -- Dependencies: 10
 -- Name: komentar_seq; Type: SEQUENCE; Schema: nekurak; Owner: nekurak
 --
@@ -283,8 +268,8 @@
 ALTER TABLE nekurak.komentar_seq OWNER TO nekurak;
 
 --
--- TOC entry 1615 (class 1259 OID 35376)
--- Dependencies: 1900 1901 10
+-- TOC entry 1616 (class 1259 OID 35376)
+-- Dependencies: 1902 1903 10
 -- Name: komentar; Type: TABLE; Schema: nekurak; Owner: nekurak; Tablespace: 
 --
 
@@ -301,8 +286,8 @@
 ALTER TABLE nekurak.komentar OWNER TO nekurak;
 
 --
--- TOC entry 1960 (class 0 OID 0)
--- Dependencies: 1615
+-- TOC entry 1963 (class 0 OID 0)
+-- Dependencies: 1616
 -- Name: TABLE komentar; Type: COMMENT; Schema: nekurak; Owner: nekurak
 --
 
@@ -310,8 +295,8 @@
 
 
 --
--- TOC entry 1961 (class 0 OID 0)
--- Dependencies: 1615
+-- TOC entry 1964 (class 0 OID 0)
+-- Dependencies: 1616
 -- Name: COLUMN komentar.nadpis; Type: COMMENT; Schema: nekurak; Owner: nekurak
 --
 
@@ -319,8 +304,8 @@
 
 
 --
--- TOC entry 1962 (class 0 OID 0)
--- Dependencies: 1615
+-- TOC entry 1965 (class 0 OID 0)
+-- Dependencies: 1616
 -- Name: COLUMN komentar.komentar; Type: COMMENT; Schema: nekurak; Owner: nekurak
 --
 
@@ -329,7 +314,30 @@
 
 
 --
--- TOC entry 1601 (class 1259 OID 35019)
+-- TOC entry 1619 (class 1259 OID 35436)
+-- Dependencies: 10
+-- Name: kurackost; Type: TABLE; Schema: nekurak; Owner: nekurak; Tablespace: 
+--
+
+CREATE TABLE kurackost (
+    id integer NOT NULL,
+    popis character varying(64)
+);
+
+
+ALTER TABLE nekurak.kurackost OWNER TO nekurak;
+
+--
+-- TOC entry 1967 (class 0 OID 0)
+-- Dependencies: 1619
+-- Name: TABLE kurackost; Type: COMMENT; Schema: nekurak; Owner: nekurak
+--
+
+COMMENT ON TABLE kurackost IS 'Kuřáckost podniku – zda se tu kouří, nekouří, nebo jen částečně atd.';
+
+
+--
+-- TOC entry 1602 (class 1259 OID 35019)
 -- Dependencies: 10
 -- Name: podnik_seq; Type: SEQUENCE; Schema: nekurak; Owner: nekurak
 --
@@ -344,8 +352,8 @@
 ALTER TABLE nekurak.podnik_seq OWNER TO nekurak;
 
 --
--- TOC entry 1602 (class 1259 OID 35049)
--- Dependencies: 1890 1891 1892 10
+-- TOC entry 1603 (class 1259 OID 35049)
+-- Dependencies: 1891 1892 1893 1894 10
 -- Name: podnik; Type: TABLE; Schema: nekurak; Owner: nekurak; Tablespace: 
 --
 
@@ -361,16 +369,16 @@
     spravce character varying(64),
     sirka double precision,
     delka double precision,
-    stav character(1),
-    CONSTRAINT stav_tg CHECK (((stav = ANY (ARRAY['k'::bpchar, 'n'::bpchar, 'o'::bpchar, 'c'::bpchar])) OR (stav IS NULL)))
+    kurackost integer DEFAULT 0 NOT NULL,
+    schvaleny boolean DEFAULT false NOT NULL
 );
 
 
 ALTER TABLE nekurak.podnik OWNER TO nekurak;
 
 --
--- TOC entry 1965 (class 0 OID 0)
--- Dependencies: 1602
+-- TOC entry 1970 (class 0 OID 0)
+-- Dependencies: 1603
 -- Name: COLUMN podnik.spravce; Type: COMMENT; Schema: nekurak; Owner: nekurak
 --
 
@@ -378,19 +386,6 @@
 
 
 --
--- TOC entry 1966 (class 0 OID 0)
--- Dependencies: 1602
--- Name: CONSTRAINT stav_tg ON podnik; Type: COMMENT; Schema: nekurak; Owner: nekurak
---
-
-COMMENT ON CONSTRAINT stav_tg ON podnik IS 'k = kuřácký
-n = nekuřácký
-o = oddělené části (důkladně)
-c = částečně kuřácký (špatně oddělené, považujeme za kuřácký)
-NULL = neznámý stav';
-
-
---
 -- TOC entry 1618 (class 1259 OID 35404)
 -- Dependencies: 10
 -- Name: podnik_kategorie; Type: TABLE; Schema: nekurak; Owner: nekurak; Tablespace: 
@@ -405,7 +400,7 @@
 ALTER TABLE nekurak.podnik_kategorie OWNER TO nekurak;
 
 --
--- TOC entry 1605 (class 1259 OID 35101)
+-- TOC entry 1606 (class 1259 OID 35101)
 -- Dependencies: 10
 -- Name: role; Type: TABLE; Schema: nekurak; Owner: nekurak; Tablespace: 
 --
@@ -419,8 +414,8 @@
 ALTER TABLE nekurak.role OWNER TO nekurak;
 
 --
--- TOC entry 1969 (class 0 OID 0)
--- Dependencies: 1605
+-- TOC entry 1973 (class 0 OID 0)
+-- Dependencies: 1606
 -- Name: TABLE role; Type: COMMENT; Schema: nekurak; Owner: nekurak
 --
 
@@ -428,7 +423,7 @@
 
 
 --
--- TOC entry 1603 (class 1259 OID 35080)
+-- TOC entry 1604 (class 1259 OID 35080)
 -- Dependencies: 10
 -- Name: uzivatel_seq; Type: SEQUENCE; Schema: nekurak; Owner: nekurak
 --
@@ -443,8 +438,8 @@
 ALTER TABLE nekurak.uzivatel_seq OWNER TO nekurak;
 
 --
--- TOC entry 1604 (class 1259 OID 35091)
--- Dependencies: 1893 1894 10
+-- TOC entry 1605 (class 1259 OID 35091)
+-- Dependencies: 1895 1896 10
 -- Name: uzivatel; Type: TABLE; Schema: nekurak; Owner: nekurak; Tablespace: 
 --
 
@@ -462,8 +457,8 @@
 ALTER TABLE nekurak.uzivatel OWNER TO nekurak;
 
 --
--- TOC entry 1972 (class 0 OID 0)
--- Dependencies: 1604
+-- TOC entry 1976 (class 0 OID 0)
+-- Dependencies: 1605
 -- Name: COLUMN uzivatel.prezdivka; Type: COMMENT; Schema: nekurak; Owner: nekurak
 --
 
@@ -471,7 +466,7 @@
 
 
 --
--- TOC entry 1606 (class 1259 OID 35106)
+-- TOC entry 1607 (class 1259 OID 35106)
 -- Dependencies: 10
 -- Name: uzivatel_role; Type: TABLE; Schema: nekurak; Owner: nekurak; Tablespace: 
 --
@@ -485,8 +480,8 @@
 ALTER TABLE nekurak.uzivatel_role OWNER TO nekurak;
 
 --
--- TOC entry 1974 (class 0 OID 0)
--- Dependencies: 1606
+-- TOC entry 1978 (class 0 OID 0)
+-- Dependencies: 1607
 -- Name: TABLE uzivatel_role; Type: COMMENT; Schema: nekurak; Owner: nekurak
 --
 
@@ -494,8 +489,8 @@
 
 
 --
--- TOC entry 1918 (class 2606 OID 35227)
--- Dependencies: 1609 1609
+-- TOC entry 1919 (class 2606 OID 35227)
+-- Dependencies: 1610 1610
 -- Name: clanek_pk; Type: CONSTRAINT; Schema: nekurak; Owner: nekurak; Tablespace: 
 --
 
@@ -504,8 +499,8 @@
 
 
 --
--- TOC entry 1914 (class 2606 OID 35190)
--- Dependencies: 1608 1608
+-- TOC entry 1915 (class 2606 OID 35190)
+-- Dependencies: 1609 1609
 -- Name: fotka_pk; Type: CONSTRAINT; Schema: nekurak; Owner: nekurak; Tablespace: 
 --
 
@@ -514,8 +509,8 @@
 
 
 --
--- TOC entry 1916 (class 2606 OID 35204)
--- Dependencies: 1608 1608 1608
+-- TOC entry 1917 (class 2606 OID 35204)
+-- Dependencies: 1609 1609 1609
 -- Name: fotka_poradi_uq; Type: CONSTRAINT; Schema: nekurak; Owner: nekurak; Tablespace: 
 --
 
@@ -524,8 +519,8 @@
 
 
 --
--- TOC entry 1921 (class 2606 OID 35284)
--- Dependencies: 1613 1613
+-- TOC entry 1922 (class 2606 OID 35284)
+-- Dependencies: 1614 1614
 -- Name: hlasovani_pk; Type: CONSTRAINT; Schema: nekurak; Owner: nekurak; Tablespace: 
 --
 
@@ -534,7 +529,7 @@
 
 
 --
--- TOC entry 1926 (class 2606 OID 35403)
+-- TOC entry 1927 (class 2606 OID 35403)
 -- Dependencies: 1617 1617
 -- Name: kategorie_pk; Type: CONSTRAINT; Schema: nekurak; Owner: nekurak; Tablespace: 
 --
@@ -544,8 +539,8 @@
 
 
 --
--- TOC entry 1924 (class 2606 OID 35385)
--- Dependencies: 1615 1615
+-- TOC entry 1925 (class 2606 OID 35385)
+-- Dependencies: 1616 1616
 -- Name: komentar_pk; Type: CONSTRAINT; Schema: nekurak; Owner: nekurak; Tablespace: 
 --
 
@@ -554,7 +549,17 @@
 
 
 --
--- TOC entry 1928 (class 2606 OID 35408)
+-- TOC entry 1931 (class 2606 OID 35441)
+-- Dependencies: 1619 1619
+-- Name: kurackost_pk; Type: CONSTRAINT; Schema: nekurak; Owner: nekurak; Tablespace: 
+--
+
+ALTER TABLE ONLY kurackost
+    ADD CONSTRAINT kurackost_pk PRIMARY KEY (id);
+
+
+--
+-- TOC entry 1929 (class 2606 OID 35408)
 -- Dependencies: 1618 1618 1618
 -- Name: podnik_kategorie_pk; Type: CONSTRAINT; Schema: nekurak; Owner: nekurak; Tablespace: 
 --
@@ -564,8 +569,8 @@
 
 
 --
--- TOC entry 1904 (class 2606 OID 35058)
--- Dependencies: 1602 1602
+-- TOC entry 1905 (class 2606 OID 35058)
+-- Dependencies: 1603 1603
 -- Name: podnik_pk; Type: CONSTRAINT; Schema: nekurak; Owner: nekurak; Tablespace: 
 --
 
@@ -574,8 +579,8 @@
 
 
 --
--- TOC entry 1910 (class 2606 OID 35105)
--- Dependencies: 1605 1605
+-- TOC entry 1911 (class 2606 OID 35105)
+-- Dependencies: 1606 1606
 -- Name: skupina_pk; Type: CONSTRAINT; Schema: nekurak; Owner: nekurak; Tablespace: 
 --
 
@@ -584,8 +589,8 @@
 
 
 --
--- TOC entry 1906 (class 2606 OID 35098)
--- Dependencies: 1604 1604
+-- TOC entry 1907 (class 2606 OID 35098)
+-- Dependencies: 1605 1605
 -- Name: uzivatel_pk; Type: CONSTRAINT; Schema: nekurak; Owner: nekurak; Tablespace: 
 --
 
@@ -594,8 +599,8 @@
 
 
 --
--- TOC entry 1908 (class 2606 OID 35100)
--- Dependencies: 1604 1604
+-- TOC entry 1909 (class 2606 OID 35100)
+-- Dependencies: 1605 1605
 -- Name: uzivatel_prezdivka_uq; Type: CONSTRAINT; Schema: nekurak; Owner: nekurak; Tablespace: 
 --
 
@@ -604,8 +609,8 @@
 
 
 --
--- TOC entry 1912 (class 2606 OID 35137)
--- Dependencies: 1606 1606 1606
+-- TOC entry 1913 (class 2606 OID 35137)
+-- Dependencies: 1607 1607 1607
 -- Name: uzivatel_role_pk; Type: CONSTRAINT; Schema: nekurak; Owner: nekurak; Tablespace: 
 --
 
@@ -614,8 +619,8 @@
 
 
 --
--- TOC entry 1919 (class 1259 OID 35291)
--- Dependencies: 1613
+-- TOC entry 1920 (class 1259 OID 35291)
+-- Dependencies: 1614
 -- Name: hlasovani_ip_idx; Type: INDEX; Schema: nekurak; Owner: nekurak; Tablespace: 
 --
 
@@ -623,8 +628,8 @@
 
 
 --
--- TOC entry 1922 (class 1259 OID 35309)
--- Dependencies: 1613
+-- TOC entry 1923 (class 1259 OID 35309)
+-- Dependencies: 1614
 -- Name: hlsovani_datum_idx; Type: INDEX; Schema: nekurak; Owner: nekurak; Tablespace: 
 --
 
@@ -632,8 +637,8 @@
 
 
 --
--- TOC entry 1938 (class 2620 OID 35125)
--- Dependencies: 1604 65
+-- TOC entry 1942 (class 2620 OID 35125)
+-- Dependencies: 65 1605
 -- Name: uzivatel_insert; Type: TRIGGER; Schema: nekurak; Owner: nekurak
 --
 
@@ -644,8 +649,8 @@
 
 
 --
--- TOC entry 1932 (class 2606 OID 35191)
--- Dependencies: 1903 1608 1602
+-- TOC entry 1936 (class 2606 OID 35191)
+-- Dependencies: 1904 1603 1609
 -- Name: fotka_podnik_fk; Type: FK CONSTRAINT; Schema: nekurak; Owner: nekurak
 --
 
@@ -654,8 +659,8 @@
 
 
 --
--- TOC entry 1933 (class 2606 OID 35285)
--- Dependencies: 1903 1602 1613
+-- TOC entry 1937 (class 2606 OID 35285)
+-- Dependencies: 1614 1603 1904
 -- Name: hlasovani_podnik_fk; Type: FK CONSTRAINT; Schema: nekurak; Owner: nekurak
 --
 
@@ -664,8 +669,8 @@
 
 
 --
--- TOC entry 1934 (class 2606 OID 35386)
--- Dependencies: 1615 1602 1903
+-- TOC entry 1938 (class 2606 OID 35386)
+-- Dependencies: 1904 1603 1616
 -- Name: komentar_podnik_fk; Type: FK CONSTRAINT; Schema: nekurak; Owner: nekurak
 --
 
@@ -674,8 +679,8 @@
 
 
 --
--- TOC entry 1935 (class 2606 OID 35391)
--- Dependencies: 1907 1604 1615
+-- TOC entry 1939 (class 2606 OID 35391)
+-- Dependencies: 1616 1908 1605
 -- Name: komentar_uzivatel_fk; Type: FK CONSTRAINT; Schema: nekurak; Owner: nekurak
 --
 
@@ -684,8 +689,8 @@
 
 
 --
--- TOC entry 1937 (class 2606 OID 35414)
--- Dependencies: 1618 1925 1617
+-- TOC entry 1941 (class 2606 OID 35414)
+-- Dependencies: 1926 1617 1618
 -- Name: podnik_kategorie_kategorie_fk; Type: FK CONSTRAINT; Schema: nekurak; Owner: nekurak
 --
 
@@ -694,8 +699,8 @@
 
 
 --
--- TOC entry 1936 (class 2606 OID 35409)
--- Dependencies: 1903 1602 1618
+-- TOC entry 1940 (class 2606 OID 35409)
+-- Dependencies: 1603 1618 1904
 -- Name: podnik_kategorie_podnik_fk; Type: FK CONSTRAINT; Schema: nekurak; Owner: nekurak
 --
 
@@ -704,8 +709,18 @@
 
 
 --
--- TOC entry 1929 (class 2606 OID 35178)
--- Dependencies: 1602 1604 1907
+-- TOC entry 1933 (class 2606 OID 35458)
+-- Dependencies: 1603 1619 1930
+-- Name: podnik_kurackost_fk; Type: FK CONSTRAINT; Schema: nekurak; Owner: nekurak
+--
+
+ALTER TABLE ONLY podnik
+    ADD CONSTRAINT podnik_kurackost_fk FOREIGN KEY (kurackost) REFERENCES kurackost(id);
+
+
+--
+-- TOC entry 1932 (class 2606 OID 35178)
+-- Dependencies: 1603 1605 1908
 -- Name: podnik_uzivatel_fk; Type: FK CONSTRAINT; Schema: nekurak; Owner: nekurak
 --
 
@@ -714,8 +729,8 @@
 
 
 --
--- TOC entry 1930 (class 2606 OID 35138)
--- Dependencies: 1909 1606 1605
+-- TOC entry 1934 (class 2606 OID 35138)
+-- Dependencies: 1607 1910 1606
 -- Name: uzivatel_role_role_fk; Type: FK CONSTRAINT; Schema: nekurak; Owner: nekurak
 --
 
@@ -724,8 +739,8 @@
 
 
 --
--- TOC entry 1931 (class 2606 OID 35143)
--- Dependencies: 1907 1604 1606
+-- TOC entry 1935 (class 2606 OID 35143)
+-- Dependencies: 1605 1607 1908
 -- Name: uzivatel_role_uzivatel_fk; Type: FK CONSTRAINT; Schema: nekurak; Owner: nekurak
 --
 
@@ -734,7 +749,7 @@
 
 
 --
--- TOC entry 1941 (class 0 OID 0)
+-- TOC entry 1945 (class 0 OID 0)
 -- Dependencies: 10
 -- Name: nekurak; Type: ACL; Schema: -; Owner: nekurak
 --
@@ -746,8 +761,8 @@
 
 
 --
--- TOC entry 1944 (class 0 OID 0)
--- Dependencies: 1610
+-- TOC entry 1948 (class 0 OID 0)
+-- Dependencies: 1611
 -- Name: clanek_seq; Type: ACL; Schema: nekurak; Owner: nekurak
 --
 
@@ -758,8 +773,8 @@
 
 
 --
--- TOC entry 1946 (class 0 OID 0)
--- Dependencies: 1609
+-- TOC entry 1950 (class 0 OID 0)
+-- Dependencies: 1610
 -- Name: clanek; Type: ACL; Schema: nekurak; Owner: nekurak
 --
 
@@ -770,8 +785,8 @@
 
 
 --
--- TOC entry 1947 (class 0 OID 0)
--- Dependencies: 1607
+-- TOC entry 1951 (class 0 OID 0)
+-- Dependencies: 1608
 -- Name: fotka_seq; Type: ACL; Schema: nekurak; Owner: nekurak
 --
 
@@ -782,8 +797,8 @@
 
 
 --
--- TOC entry 1950 (class 0 OID 0)
--- Dependencies: 1608
+-- TOC entry 1954 (class 0 OID 0)
+-- Dependencies: 1609
 -- Name: fotka; Type: ACL; Schema: nekurak; Owner: nekurak
 --
 
@@ -794,8 +809,8 @@
 
 
 --
--- TOC entry 1951 (class 0 OID 0)
--- Dependencies: 1612
+-- TOC entry 1955 (class 0 OID 0)
+-- Dependencies: 1613
 -- Name: hlasovani_seq; Type: ACL; Schema: nekurak; Owner: nekurak
 --
 
@@ -806,8 +821,8 @@
 
 
 --
--- TOC entry 1954 (class 0 OID 0)
--- Dependencies: 1613
+-- TOC entry 1958 (class 0 OID 0)
+-- Dependencies: 1614
 -- Name: hlasovani; Type: ACL; Schema: nekurak; Owner: nekurak
 --
 
@@ -818,19 +833,7 @@
 
 
 --
--- TOC entry 1955 (class 0 OID 0)
--- Dependencies: 1616
--- Name: kategorie_seq; Type: ACL; Schema: nekurak; Owner: nekurak
---
-
-REVOKE ALL ON SEQUENCE kategorie_seq FROM PUBLIC;
-REVOKE ALL ON SEQUENCE kategorie_seq FROM nekurak;
-GRANT ALL ON SEQUENCE kategorie_seq TO nekurak;
-GRANT USAGE ON SEQUENCE kategorie_seq TO nekurak_web;
-
-
---
--- TOC entry 1958 (class 0 OID 0)
+-- TOC entry 1961 (class 0 OID 0)
 -- Dependencies: 1617
 -- Name: kategorie; Type: ACL; Schema: nekurak; Owner: nekurak
 --
@@ -838,12 +841,12 @@
 REVOKE ALL ON TABLE kategorie FROM PUBLIC;
 REVOKE ALL ON TABLE kategorie FROM nekurak;
 GRANT ALL ON TABLE kategorie TO nekurak;
-GRANT SELECT,INSERT,DELETE,UPDATE ON TABLE kategorie TO nekurak_web;
+GRANT SELECT ON TABLE kategorie TO nekurak_web;
 
 
 --
--- TOC entry 1959 (class 0 OID 0)
--- Dependencies: 1614
+-- TOC entry 1962 (class 0 OID 0)
+-- Dependencies: 1615
 -- Name: komentar_seq; Type: ACL; Schema: nekurak; Owner: nekurak
 --
 
@@ -854,8 +857,8 @@
 
 
 --
--- TOC entry 1963 (class 0 OID 0)
--- Dependencies: 1615
+-- TOC entry 1966 (class 0 OID 0)
+-- Dependencies: 1616
 -- Name: komentar; Type: ACL; Schema: nekurak; Owner: nekurak
 --
 
@@ -866,8 +869,20 @@
 
 
 --
--- TOC entry 1964 (class 0 OID 0)
--- Dependencies: 1601
+-- TOC entry 1968 (class 0 OID 0)
+-- Dependencies: 1619
+-- Name: kurackost; Type: ACL; Schema: nekurak; Owner: nekurak
+--
+
+REVOKE ALL ON TABLE kurackost FROM PUBLIC;
+REVOKE ALL ON TABLE kurackost FROM nekurak;
+GRANT ALL ON TABLE kurackost TO nekurak;
+GRANT SELECT ON TABLE kurackost TO nekurak_web;
+
+
+--
+-- TOC entry 1969 (class 0 OID 0)
+-- Dependencies: 1602
 -- Name: podnik_seq; Type: ACL; Schema: nekurak; Owner: nekurak
 --
 
@@ -878,8 +893,8 @@
 
 
 --
--- TOC entry 1967 (class 0 OID 0)
--- Dependencies: 1602
+-- TOC entry 1971 (class 0 OID 0)
+-- Dependencies: 1603
 -- Name: podnik; Type: ACL; Schema: nekurak; Owner: nekurak
 --
 
@@ -890,7 +905,7 @@
 
 
 --
--- TOC entry 1968 (class 0 OID 0)
+-- TOC entry 1972 (class 0 OID 0)
 -- Dependencies: 1618
 -- Name: podnik_kategorie; Type: ACL; Schema: nekurak; Owner: nekurak
 --
@@ -902,8 +917,8 @@
 
 
 --
--- TOC entry 1970 (class 0 OID 0)
--- Dependencies: 1605
+-- TOC entry 1974 (class 0 OID 0)
+-- Dependencies: 1606
 -- Name: role; Type: ACL; Schema: nekurak; Owner: nekurak
 --
 
@@ -914,8 +929,8 @@
 
 
 --
--- TOC entry 1971 (class 0 OID 0)
--- Dependencies: 1603
+-- TOC entry 1975 (class 0 OID 0)
+-- Dependencies: 1604
 -- Name: uzivatel_seq; Type: ACL; Schema: nekurak; Owner: nekurak
 --
 
@@ -926,8 +941,8 @@
 
 
 --
--- TOC entry 1973 (class 0 OID 0)
--- Dependencies: 1604
+-- TOC entry 1977 (class 0 OID 0)
+-- Dependencies: 1605
 -- Name: uzivatel; Type: ACL; Schema: nekurak; Owner: nekurak
 --
 
@@ -938,8 +953,8 @@
 
 
 --
--- TOC entry 1975 (class 0 OID 0)
--- Dependencies: 1606
+-- TOC entry 1979 (class 0 OID 0)
+-- Dependencies: 1607
 -- Name: uzivatel_role; Type: ACL; Schema: nekurak; Owner: nekurak
 --
 
@@ -949,7 +964,7 @@
 GRANT SELECT,INSERT,DELETE,UPDATE ON TABLE uzivatel_role TO nekurak_web;
 
 
--- Completed on 2011-01-11 15:26:23 CET
+-- Completed on 2011-01-15 14:24:31 CET
 
 --
 -- PostgreSQL database dump complete




