Základ servletu pro zobrazování detailu podniku.
2 -- PostgreSQL database dump
5 -- Started on 2011-01-15 14:24:29 CET
7 SET statement_timeout = 0;
8 SET client_encoding = 'UTF8';
9 SET standard_conforming_strings = off;
10 SET check_function_bodies = false;
11 SET client_min_messages = warning;
12 SET escape_string_warning = off;
15 -- TOC entry 10 (class 2615 OID 35015)
16 -- Name: nekurak; Type: SCHEMA; Schema: -; Owner: nekurak
19 CREATE SCHEMA nekurak;
22 ALTER SCHEMA nekurak OWNER TO nekurak;
24 SET search_path = nekurak, pg_catalog;
27 -- TOC entry 366 (class 1247 OID 35086)
28 -- Dependencies: 367 10
29 -- Name: email; Type: DOMAIN; Schema: nekurak; Owner: nekurak
32 CREATE DOMAIN email AS character varying(255)
33 CONSTRAINT email_regexp CHECK (((VALUE)::text ~ '^[_a-zA-Z0-9\\.\\-]+@[_a-zA-Z0-9\\.\\-]+\\.[a-zA-Z]{2,4}$'::text));
36 ALTER DOMAIN nekurak.email OWNER TO nekurak;
39 -- TOC entry 1946 (class 0 OID 0)
41 -- Name: DOMAIN email; Type: COMMENT; Schema: nekurak; Owner: nekurak
44 COMMENT ON DOMAIN email IS 'e-mailová adresa';
48 -- TOC entry 65 (class 1255 OID 35124)
49 -- Dependencies: 412 10
50 -- Name: bezny_uzivatel(); Type: FUNCTION; Schema: nekurak; Owner: nekurak
53 CREATE FUNCTION bezny_uzivatel() RETURNS trigger
56 INSERT INTO uzivatel_role
59 ('bezny', new.prezdivka);
64 ALTER FUNCTION nekurak.bezny_uzivatel() OWNER TO nekurak;
67 -- TOC entry 1947 (class 0 OID 0)
69 -- Name: FUNCTION bezny_uzivatel(); Type: COMMENT; Schema: nekurak; Owner: nekurak
72 COMMENT ON FUNCTION bezny_uzivatel() IS 'Každému novému uživateli dáme automaticky roli „bezny“.';
76 -- TOC entry 1611 (class 1259 OID 35223)
78 -- Name: clanek_seq; Type: SEQUENCE; Schema: nekurak; Owner: nekurak
81 CREATE SEQUENCE clanek_seq
88 ALTER TABLE nekurak.clanek_seq OWNER TO nekurak;
90 SET default_tablespace = '';
92 SET default_with_oids = false;
95 -- TOC entry 1610 (class 1259 OID 35205)
96 -- Dependencies: 1899 10
97 -- Name: clanek; Type: TABLE; Schema: nekurak; Owner: nekurak; Tablespace:
100 CREATE TABLE clanek (
101 id integer DEFAULT nextval('clanek_seq'::regclass) NOT NULL,
102 nadpis character varying(255) NOT NULL,
107 ALTER TABLE nekurak.clanek OWNER TO nekurak;
110 -- TOC entry 1949 (class 0 OID 0)
111 -- Dependencies: 1610
112 -- Name: TABLE clanek; Type: COMMENT; Schema: nekurak; Owner: nekurak
115 COMMENT ON TABLE clanek IS 'Článek potažmo stránka – nějaký textový obsah (XHTML).';
119 -- TOC entry 1608 (class 1259 OID 35183)
121 -- Name: fotka_seq; Type: SEQUENCE; Schema: nekurak; Owner: nekurak
124 CREATE SEQUENCE fotka_seq
132 ALTER TABLE nekurak.fotka_seq OWNER TO nekurak;
135 -- TOC entry 1609 (class 1259 OID 35185)
136 -- Dependencies: 1897 1898 10
137 -- Name: fotka; Type: TABLE; Schema: nekurak; Owner: nekurak; Tablespace:
141 id integer DEFAULT nextval('fotka_seq'::regclass) NOT NULL,
142 podnik integer NOT NULL,
143 popis character varying(255),
144 poradi integer DEFAULT 0 NOT NULL
148 ALTER TABLE nekurak.fotka OWNER TO nekurak;
151 -- TOC entry 1952 (class 0 OID 0)
152 -- Dependencies: 1609
153 -- Name: TABLE fotka; Type: COMMENT; Schema: nekurak; Owner: nekurak
156 COMMENT ON TABLE fotka IS 'Fotka podniku.';
160 -- TOC entry 1953 (class 0 OID 0)
161 -- Dependencies: 1609
162 -- Name: COLUMN fotka.poradi; Type: COMMENT; Schema: nekurak; Owner: nekurak
165 COMMENT ON COLUMN fotka.poradi IS 'Pořadí fotky v rámci daného podniku.';
169 -- TOC entry 1613 (class 1259 OID 35250)
171 -- Name: hlasovani_seq; Type: SEQUENCE; Schema: nekurak; Owner: nekurak
174 CREATE SEQUENCE hlasovani_seq
181 ALTER TABLE nekurak.hlasovani_seq OWNER TO nekurak;
184 -- TOC entry 1614 (class 1259 OID 35278)
185 -- Dependencies: 1900 1901 10
186 -- Name: hlasovani; Type: TABLE; Schema: nekurak; Owner: nekurak; Tablespace:
189 CREATE TABLE hlasovani (
190 id integer DEFAULT nextval('hlasovani_seq'::regclass) NOT NULL,
191 podnik integer NOT NULL,
192 hlas boolean NOT NULL,
193 datum timestamp without time zone DEFAULT now() NOT NULL,
194 ip_adresa character varying(255) NOT NULL
198 ALTER TABLE nekurak.hlasovani OWNER TO nekurak;
201 -- TOC entry 1956 (class 0 OID 0)
202 -- Dependencies: 1614
203 -- Name: COLUMN hlasovani.id; Type: COMMENT; Schema: nekurak; Owner: nekurak
206 COMMENT ON COLUMN hlasovani.id IS 'V této tabulce v princupu ID nepotřebujeme,
207 protože nebudeme adresovat konkrétní záznamy (a i kdyby, můžeme použít OID).
208 Ale číselné ID se nám bude hodit pro rychlejší nalezení posledního hlasu od dané IP adresy.';
212 -- TOC entry 1957 (class 0 OID 0)
213 -- Dependencies: 1614
214 -- Name: COLUMN hlasovani.hlas; Type: COMMENT; Schema: nekurak; Owner: nekurak
217 COMMENT ON COLUMN hlasovani.hlas IS 'Má být tento podnik nekuřácký?
219 false = kouření povoleno';
223 -- TOC entry 1617 (class 1259 OID 35398)
225 -- Name: kategorie; Type: TABLE; Schema: nekurak; Owner: nekurak; Tablespace:
228 CREATE TABLE kategorie (
230 nazev character varying(32) NOT NULL
234 ALTER TABLE nekurak.kategorie OWNER TO nekurak;
237 -- TOC entry 1959 (class 0 OID 0)
238 -- Dependencies: 1617
239 -- Name: TABLE kategorie; Type: COMMENT; Schema: nekurak; Owner: nekurak
242 COMMENT ON TABLE kategorie IS 'Kategorie podniku';
246 -- TOC entry 1960 (class 0 OID 0)
247 -- Dependencies: 1617
248 -- Name: COLUMN kategorie.nazev; Type: COMMENT; Schema: nekurak; Owner: nekurak
251 COMMENT ON COLUMN kategorie.nazev IS 'jen pro info při přímé práci s SQL
252 aplikace bere názvy a popisy kategorií z lokalizačního souboru (na základě ID kategorie)';
256 -- TOC entry 1615 (class 1259 OID 35333)
258 -- Name: komentar_seq; Type: SEQUENCE; Schema: nekurak; Owner: nekurak
261 CREATE SEQUENCE komentar_seq
268 ALTER TABLE nekurak.komentar_seq OWNER TO nekurak;
271 -- TOC entry 1616 (class 1259 OID 35376)
272 -- Dependencies: 1902 1903 10
273 -- Name: komentar; Type: TABLE; Schema: nekurak; Owner: nekurak; Tablespace:
276 CREATE TABLE komentar (
277 id integer DEFAULT nextval('komentar_seq'::regclass) NOT NULL,
278 podnik integer NOT NULL,
279 uzivatel character varying(64) NOT NULL,
280 datum timestamp with time zone DEFAULT now() NOT NULL,
281 nadpis character varying(255),
282 komentar text NOT NULL
286 ALTER TABLE nekurak.komentar OWNER TO nekurak;
289 -- TOC entry 1963 (class 0 OID 0)
290 -- Dependencies: 1616
291 -- Name: TABLE komentar; Type: COMMENT; Schema: nekurak; Owner: nekurak
294 COMMENT ON TABLE komentar IS 'Komentář k podniku';
298 -- TOC entry 1964 (class 0 OID 0)
299 -- Dependencies: 1616
300 -- Name: COLUMN komentar.nadpis; Type: COMMENT; Schema: nekurak; Owner: nekurak
303 COMMENT ON COLUMN komentar.nadpis IS 'vždy jen prostý text';
307 -- TOC entry 1965 (class 0 OID 0)
308 -- Dependencies: 1616
309 -- Name: COLUMN komentar.komentar; Type: COMMENT; Schema: nekurak; Owner: nekurak
312 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.
313 Jedná se o kus validního XML – má kořenový element <div/>';
317 -- TOC entry 1619 (class 1259 OID 35436)
319 -- Name: kurackost; Type: TABLE; Schema: nekurak; Owner: nekurak; Tablespace:
322 CREATE TABLE kurackost (
324 popis character varying(64)
328 ALTER TABLE nekurak.kurackost OWNER TO nekurak;
331 -- TOC entry 1967 (class 0 OID 0)
332 -- Dependencies: 1619
333 -- Name: TABLE kurackost; Type: COMMENT; Schema: nekurak; Owner: nekurak
336 COMMENT ON TABLE kurackost IS 'Kuřáckost podniku – zda se tu kouří, nekouří, nebo jen částečně atd.';
340 -- TOC entry 1602 (class 1259 OID 35019)
342 -- Name: podnik_seq; Type: SEQUENCE; Schema: nekurak; Owner: nekurak
345 CREATE SEQUENCE podnik_seq
352 ALTER TABLE nekurak.podnik_seq OWNER TO nekurak;
355 -- TOC entry 1603 (class 1259 OID 35049)
356 -- Dependencies: 1891 1892 1893 1894 10
357 -- Name: podnik; Type: TABLE; Schema: nekurak; Owner: nekurak; Tablespace:
360 CREATE TABLE podnik (
361 id integer DEFAULT nextval('podnik_seq'::regclass) NOT NULL,
362 nazev character varying(255) NOT NULL,
363 popis character varying(255),
364 url character varying(255),
365 datum timestamp with time zone DEFAULT now(),
366 ulice character varying(64),
367 cislo_popisne integer,
368 mesto character varying(64),
369 spravce character varying(64),
370 sirka double precision,
371 delka double precision,
372 kurackost integer DEFAULT 0 NOT NULL,
373 schvaleny boolean DEFAULT false NOT NULL
377 ALTER TABLE nekurak.podnik OWNER TO nekurak;
380 -- TOC entry 1970 (class 0 OID 0)
381 -- Dependencies: 1603
382 -- Name: COLUMN podnik.spravce; Type: COMMENT; Schema: nekurak; Owner: nekurak
385 COMMENT ON COLUMN podnik.spravce IS 'Přezdívka uživatele, který je správcem tohoto podniku (zadal ho do systému nebo správcovství později dostal)';
389 -- TOC entry 1618 (class 1259 OID 35404)
391 -- Name: podnik_kategorie; Type: TABLE; Schema: nekurak; Owner: nekurak; Tablespace:
394 CREATE TABLE podnik_kategorie (
395 podnik integer NOT NULL,
396 kategorie integer NOT NULL
400 ALTER TABLE nekurak.podnik_kategorie OWNER TO nekurak;
403 -- TOC entry 1606 (class 1259 OID 35101)
405 -- Name: role; Type: TABLE; Schema: nekurak; Owner: nekurak; Tablespace:
409 kod character varying(16) NOT NULL,
410 popis character varying(255)
414 ALTER TABLE nekurak.role OWNER TO nekurak;
417 -- TOC entry 1973 (class 0 OID 0)
418 -- Dependencies: 1606
419 -- Name: TABLE role; Type: COMMENT; Schema: nekurak; Owner: nekurak
422 COMMENT ON TABLE role IS 'Role (skupiny) uživatelů ~ oprávnění';
426 -- TOC entry 1604 (class 1259 OID 35080)
428 -- Name: uzivatel_seq; Type: SEQUENCE; Schema: nekurak; Owner: nekurak
431 CREATE SEQUENCE uzivatel_seq
438 ALTER TABLE nekurak.uzivatel_seq OWNER TO nekurak;
441 -- TOC entry 1605 (class 1259 OID 35091)
442 -- Dependencies: 1895 1896 10
443 -- Name: uzivatel; Type: TABLE; Schema: nekurak; Owner: nekurak; Tablespace:
446 CREATE TABLE uzivatel (
447 id integer DEFAULT nextval('uzivatel_seq'::regclass) NOT NULL,
448 prezdivka character varying(64) NOT NULL,
449 heslo character varying(512) NOT NULL,
450 jmeno character varying(64),
451 prijmeni character varying(64),
452 email character varying(255),
453 datum timestamp with time zone DEFAULT now() NOT NULL
457 ALTER TABLE nekurak.uzivatel OWNER TO nekurak;
460 -- TOC entry 1976 (class 0 OID 0)
461 -- Dependencies: 1605
462 -- Name: COLUMN uzivatel.prezdivka; Type: COMMENT; Schema: nekurak; Owner: nekurak
465 COMMENT ON COLUMN uzivatel.prezdivka IS 'Uživatelské jméno';
469 -- TOC entry 1607 (class 1259 OID 35106)
471 -- Name: uzivatel_role; Type: TABLE; Schema: nekurak; Owner: nekurak; Tablespace:
474 CREATE TABLE uzivatel_role (
475 role character varying(16) NOT NULL,
476 prezdivka character varying(64) NOT NULL
480 ALTER TABLE nekurak.uzivatel_role OWNER TO nekurak;
483 -- TOC entry 1978 (class 0 OID 0)
484 -- Dependencies: 1607
485 -- Name: TABLE uzivatel_role; Type: COMMENT; Schema: nekurak; Owner: nekurak
488 COMMENT ON TABLE uzivatel_role IS 'Přiřazení uživatelských rolí (skupin).';
492 -- TOC entry 1919 (class 2606 OID 35227)
493 -- Dependencies: 1610 1610
494 -- Name: clanek_pk; Type: CONSTRAINT; Schema: nekurak; Owner: nekurak; Tablespace:
497 ALTER TABLE ONLY clanek
498 ADD CONSTRAINT clanek_pk PRIMARY KEY (id);
502 -- TOC entry 1915 (class 2606 OID 35190)
503 -- Dependencies: 1609 1609
504 -- Name: fotka_pk; Type: CONSTRAINT; Schema: nekurak; Owner: nekurak; Tablespace:
507 ALTER TABLE ONLY fotka
508 ADD CONSTRAINT fotka_pk PRIMARY KEY (id);
512 -- TOC entry 1917 (class 2606 OID 35204)
513 -- Dependencies: 1609 1609 1609
514 -- Name: fotka_poradi_uq; Type: CONSTRAINT; Schema: nekurak; Owner: nekurak; Tablespace:
517 ALTER TABLE ONLY fotka
518 ADD CONSTRAINT fotka_poradi_uq UNIQUE (popis, poradi);
522 -- TOC entry 1922 (class 2606 OID 35284)
523 -- Dependencies: 1614 1614
524 -- Name: hlasovani_pk; Type: CONSTRAINT; Schema: nekurak; Owner: nekurak; Tablespace:
527 ALTER TABLE ONLY hlasovani
528 ADD CONSTRAINT hlasovani_pk PRIMARY KEY (id);
532 -- TOC entry 1927 (class 2606 OID 35403)
533 -- Dependencies: 1617 1617
534 -- Name: kategorie_pk; Type: CONSTRAINT; Schema: nekurak; Owner: nekurak; Tablespace:
537 ALTER TABLE ONLY kategorie
538 ADD CONSTRAINT kategorie_pk PRIMARY KEY (id);
542 -- TOC entry 1925 (class 2606 OID 35385)
543 -- Dependencies: 1616 1616
544 -- Name: komentar_pk; Type: CONSTRAINT; Schema: nekurak; Owner: nekurak; Tablespace:
547 ALTER TABLE ONLY komentar
548 ADD CONSTRAINT komentar_pk PRIMARY KEY (id);
552 -- TOC entry 1931 (class 2606 OID 35441)
553 -- Dependencies: 1619 1619
554 -- Name: kurackost_pk; Type: CONSTRAINT; Schema: nekurak; Owner: nekurak; Tablespace:
557 ALTER TABLE ONLY kurackost
558 ADD CONSTRAINT kurackost_pk PRIMARY KEY (id);
562 -- TOC entry 1929 (class 2606 OID 35408)
563 -- Dependencies: 1618 1618 1618
564 -- Name: podnik_kategorie_pk; Type: CONSTRAINT; Schema: nekurak; Owner: nekurak; Tablespace:
567 ALTER TABLE ONLY podnik_kategorie
568 ADD CONSTRAINT podnik_kategorie_pk PRIMARY KEY (podnik, kategorie);
572 -- TOC entry 1905 (class 2606 OID 35058)
573 -- Dependencies: 1603 1603
574 -- Name: podnik_pk; Type: CONSTRAINT; Schema: nekurak; Owner: nekurak; Tablespace:
577 ALTER TABLE ONLY podnik
578 ADD CONSTRAINT podnik_pk PRIMARY KEY (id);
582 -- TOC entry 1911 (class 2606 OID 35105)
583 -- Dependencies: 1606 1606
584 -- Name: skupina_pk; Type: CONSTRAINT; Schema: nekurak; Owner: nekurak; Tablespace:
587 ALTER TABLE ONLY role
588 ADD CONSTRAINT skupina_pk PRIMARY KEY (kod);
592 -- TOC entry 1907 (class 2606 OID 35098)
593 -- Dependencies: 1605 1605
594 -- Name: uzivatel_pk; Type: CONSTRAINT; Schema: nekurak; Owner: nekurak; Tablespace:
597 ALTER TABLE ONLY uzivatel
598 ADD CONSTRAINT uzivatel_pk PRIMARY KEY (id);
602 -- TOC entry 1909 (class 2606 OID 35100)
603 -- Dependencies: 1605 1605
604 -- Name: uzivatel_prezdivka_uq; Type: CONSTRAINT; Schema: nekurak; Owner: nekurak; Tablespace:
607 ALTER TABLE ONLY uzivatel
608 ADD CONSTRAINT uzivatel_prezdivka_uq UNIQUE (prezdivka);
612 -- TOC entry 1913 (class 2606 OID 35137)
613 -- Dependencies: 1607 1607 1607
614 -- Name: uzivatel_role_pk; Type: CONSTRAINT; Schema: nekurak; Owner: nekurak; Tablespace:
617 ALTER TABLE ONLY uzivatel_role
618 ADD CONSTRAINT uzivatel_role_pk PRIMARY KEY (role, prezdivka);
622 -- TOC entry 1920 (class 1259 OID 35291)
623 -- Dependencies: 1614
624 -- Name: hlasovani_ip_idx; Type: INDEX; Schema: nekurak; Owner: nekurak; Tablespace:
627 CREATE INDEX hlasovani_ip_idx ON hlasovani USING btree (ip_adresa);
631 -- TOC entry 1923 (class 1259 OID 35309)
632 -- Dependencies: 1614
633 -- Name: hlsovani_datum_idx; Type: INDEX; Schema: nekurak; Owner: nekurak; Tablespace:
636 CREATE INDEX hlsovani_datum_idx ON hlasovani USING btree (date(datum));
640 -- TOC entry 1942 (class 2620 OID 35125)
641 -- Dependencies: 65 1605
642 -- Name: uzivatel_insert; Type: TRIGGER; Schema: nekurak; Owner: nekurak
645 CREATE TRIGGER uzivatel_insert
646 AFTER INSERT ON uzivatel
648 EXECUTE PROCEDURE bezny_uzivatel();
652 -- TOC entry 1936 (class 2606 OID 35191)
653 -- Dependencies: 1904 1603 1609
654 -- Name: fotka_podnik_fk; Type: FK CONSTRAINT; Schema: nekurak; Owner: nekurak
657 ALTER TABLE ONLY fotka
658 ADD CONSTRAINT fotka_podnik_fk FOREIGN KEY (podnik) REFERENCES podnik(id) ON DELETE CASCADE;
662 -- TOC entry 1937 (class 2606 OID 35285)
663 -- Dependencies: 1614 1603 1904
664 -- Name: hlasovani_podnik_fk; Type: FK CONSTRAINT; Schema: nekurak; Owner: nekurak
667 ALTER TABLE ONLY hlasovani
668 ADD CONSTRAINT hlasovani_podnik_fk FOREIGN KEY (podnik) REFERENCES podnik(id) ON DELETE CASCADE;
672 -- TOC entry 1938 (class 2606 OID 35386)
673 -- Dependencies: 1904 1603 1616
674 -- Name: komentar_podnik_fk; Type: FK CONSTRAINT; Schema: nekurak; Owner: nekurak
677 ALTER TABLE ONLY komentar
678 ADD CONSTRAINT komentar_podnik_fk FOREIGN KEY (podnik) REFERENCES podnik(id);
682 -- TOC entry 1939 (class 2606 OID 35391)
683 -- Dependencies: 1616 1908 1605
684 -- Name: komentar_uzivatel_fk; Type: FK CONSTRAINT; Schema: nekurak; Owner: nekurak
687 ALTER TABLE ONLY komentar
688 ADD CONSTRAINT komentar_uzivatel_fk FOREIGN KEY (uzivatel) REFERENCES uzivatel(prezdivka);
692 -- TOC entry 1941 (class 2606 OID 35414)
693 -- Dependencies: 1926 1617 1618
694 -- Name: podnik_kategorie_kategorie_fk; Type: FK CONSTRAINT; Schema: nekurak; Owner: nekurak
697 ALTER TABLE ONLY podnik_kategorie
698 ADD CONSTRAINT podnik_kategorie_kategorie_fk FOREIGN KEY (kategorie) REFERENCES kategorie(id) ON DELETE CASCADE;
702 -- TOC entry 1940 (class 2606 OID 35409)
703 -- Dependencies: 1603 1618 1904
704 -- Name: podnik_kategorie_podnik_fk; Type: FK CONSTRAINT; Schema: nekurak; Owner: nekurak
707 ALTER TABLE ONLY podnik_kategorie
708 ADD CONSTRAINT podnik_kategorie_podnik_fk FOREIGN KEY (podnik) REFERENCES podnik(id) ON DELETE CASCADE;
712 -- TOC entry 1933 (class 2606 OID 35458)
713 -- Dependencies: 1603 1619 1930
714 -- Name: podnik_kurackost_fk; Type: FK CONSTRAINT; Schema: nekurak; Owner: nekurak
717 ALTER TABLE ONLY podnik
718 ADD CONSTRAINT podnik_kurackost_fk FOREIGN KEY (kurackost) REFERENCES kurackost(id);
722 -- TOC entry 1932 (class 2606 OID 35178)
723 -- Dependencies: 1603 1605 1908
724 -- Name: podnik_uzivatel_fk; Type: FK CONSTRAINT; Schema: nekurak; Owner: nekurak
727 ALTER TABLE ONLY podnik
728 ADD CONSTRAINT podnik_uzivatel_fk FOREIGN KEY (spravce) REFERENCES uzivatel(prezdivka) ON DELETE SET NULL;
732 -- TOC entry 1934 (class 2606 OID 35138)
733 -- Dependencies: 1607 1910 1606
734 -- Name: uzivatel_role_role_fk; Type: FK CONSTRAINT; Schema: nekurak; Owner: nekurak
737 ALTER TABLE ONLY uzivatel_role
738 ADD CONSTRAINT uzivatel_role_role_fk FOREIGN KEY (role) REFERENCES role(kod) ON UPDATE CASCADE ON DELETE CASCADE;
742 -- TOC entry 1935 (class 2606 OID 35143)
743 -- Dependencies: 1605 1607 1908
744 -- Name: uzivatel_role_uzivatel_fk; Type: FK CONSTRAINT; Schema: nekurak; Owner: nekurak
747 ALTER TABLE ONLY uzivatel_role
748 ADD CONSTRAINT uzivatel_role_uzivatel_fk FOREIGN KEY (prezdivka) REFERENCES uzivatel(prezdivka) ON UPDATE CASCADE ON DELETE CASCADE;
752 -- TOC entry 1945 (class 0 OID 0)
754 -- Name: nekurak; Type: ACL; Schema: -; Owner: nekurak
757 REVOKE ALL ON SCHEMA nekurak FROM PUBLIC;
758 REVOKE ALL ON SCHEMA nekurak FROM nekurak;
759 GRANT ALL ON SCHEMA nekurak TO nekurak;
760 GRANT USAGE ON SCHEMA nekurak TO nekurak_web;
764 -- TOC entry 1948 (class 0 OID 0)
765 -- Dependencies: 1611
766 -- Name: clanek_seq; Type: ACL; Schema: nekurak; Owner: nekurak
769 REVOKE ALL ON SEQUENCE clanek_seq FROM PUBLIC;
770 REVOKE ALL ON SEQUENCE clanek_seq FROM nekurak;
771 GRANT ALL ON SEQUENCE clanek_seq TO nekurak;
772 GRANT USAGE ON SEQUENCE clanek_seq TO nekurak_web;
776 -- TOC entry 1950 (class 0 OID 0)
777 -- Dependencies: 1610
778 -- Name: clanek; Type: ACL; Schema: nekurak; Owner: nekurak
781 REVOKE ALL ON TABLE clanek FROM PUBLIC;
782 REVOKE ALL ON TABLE clanek FROM nekurak;
783 GRANT ALL ON TABLE clanek TO nekurak;
784 GRANT SELECT,INSERT,DELETE,UPDATE ON TABLE clanek TO nekurak_web;
788 -- TOC entry 1951 (class 0 OID 0)
789 -- Dependencies: 1608
790 -- Name: fotka_seq; Type: ACL; Schema: nekurak; Owner: nekurak
793 REVOKE ALL ON SEQUENCE fotka_seq FROM PUBLIC;
794 REVOKE ALL ON SEQUENCE fotka_seq FROM nekurak;
795 GRANT ALL ON SEQUENCE fotka_seq TO nekurak;
796 GRANT USAGE ON SEQUENCE fotka_seq TO nekurak_web;
800 -- TOC entry 1954 (class 0 OID 0)
801 -- Dependencies: 1609
802 -- Name: fotka; Type: ACL; Schema: nekurak; Owner: nekurak
805 REVOKE ALL ON TABLE fotka FROM PUBLIC;
806 REVOKE ALL ON TABLE fotka FROM nekurak;
807 GRANT ALL ON TABLE fotka TO nekurak;
808 GRANT SELECT,INSERT,DELETE,UPDATE ON TABLE fotka TO nekurak_web;
812 -- TOC entry 1955 (class 0 OID 0)
813 -- Dependencies: 1613
814 -- Name: hlasovani_seq; Type: ACL; Schema: nekurak; Owner: nekurak
817 REVOKE ALL ON SEQUENCE hlasovani_seq FROM PUBLIC;
818 REVOKE ALL ON SEQUENCE hlasovani_seq FROM nekurak;
819 GRANT ALL ON SEQUENCE hlasovani_seq TO nekurak;
820 GRANT USAGE ON SEQUENCE hlasovani_seq TO nekurak_web;
824 -- TOC entry 1958 (class 0 OID 0)
825 -- Dependencies: 1614
826 -- Name: hlasovani; Type: ACL; Schema: nekurak; Owner: nekurak
829 REVOKE ALL ON TABLE hlasovani FROM PUBLIC;
830 REVOKE ALL ON TABLE hlasovani FROM nekurak;
831 GRANT ALL ON TABLE hlasovani TO nekurak;
832 GRANT SELECT,INSERT ON TABLE hlasovani TO nekurak_web;
836 -- TOC entry 1961 (class 0 OID 0)
837 -- Dependencies: 1617
838 -- Name: kategorie; Type: ACL; Schema: nekurak; Owner: nekurak
841 REVOKE ALL ON TABLE kategorie FROM PUBLIC;
842 REVOKE ALL ON TABLE kategorie FROM nekurak;
843 GRANT ALL ON TABLE kategorie TO nekurak;
844 GRANT SELECT ON TABLE kategorie TO nekurak_web;
848 -- TOC entry 1962 (class 0 OID 0)
849 -- Dependencies: 1615
850 -- Name: komentar_seq; Type: ACL; Schema: nekurak; Owner: nekurak
853 REVOKE ALL ON SEQUENCE komentar_seq FROM PUBLIC;
854 REVOKE ALL ON SEQUENCE komentar_seq FROM nekurak;
855 GRANT ALL ON SEQUENCE komentar_seq TO nekurak;
856 GRANT USAGE ON SEQUENCE komentar_seq TO nekurak_web;
860 -- TOC entry 1966 (class 0 OID 0)
861 -- Dependencies: 1616
862 -- Name: komentar; Type: ACL; Schema: nekurak; Owner: nekurak
865 REVOKE ALL ON TABLE komentar FROM PUBLIC;
866 REVOKE ALL ON TABLE komentar FROM nekurak;
867 GRANT ALL ON TABLE komentar TO nekurak;
868 GRANT SELECT,INSERT ON TABLE komentar TO nekurak_web;
872 -- TOC entry 1968 (class 0 OID 0)
873 -- Dependencies: 1619
874 -- Name: kurackost; Type: ACL; Schema: nekurak; Owner: nekurak
877 REVOKE ALL ON TABLE kurackost FROM PUBLIC;
878 REVOKE ALL ON TABLE kurackost FROM nekurak;
879 GRANT ALL ON TABLE kurackost TO nekurak;
880 GRANT SELECT ON TABLE kurackost TO nekurak_web;
884 -- TOC entry 1969 (class 0 OID 0)
885 -- Dependencies: 1602
886 -- Name: podnik_seq; Type: ACL; Schema: nekurak; Owner: nekurak
889 REVOKE ALL ON SEQUENCE podnik_seq FROM PUBLIC;
890 REVOKE ALL ON SEQUENCE podnik_seq FROM nekurak;
891 GRANT ALL ON SEQUENCE podnik_seq TO nekurak;
892 GRANT USAGE ON SEQUENCE podnik_seq TO nekurak_web;
896 -- TOC entry 1971 (class 0 OID 0)
897 -- Dependencies: 1603
898 -- Name: podnik; Type: ACL; Schema: nekurak; Owner: nekurak
901 REVOKE ALL ON TABLE podnik FROM PUBLIC;
902 REVOKE ALL ON TABLE podnik FROM nekurak;
903 GRANT ALL ON TABLE podnik TO nekurak;
904 GRANT SELECT,INSERT,DELETE,UPDATE ON TABLE podnik TO nekurak_web;
908 -- TOC entry 1972 (class 0 OID 0)
909 -- Dependencies: 1618
910 -- Name: podnik_kategorie; Type: ACL; Schema: nekurak; Owner: nekurak
913 REVOKE ALL ON TABLE podnik_kategorie FROM PUBLIC;
914 REVOKE ALL ON TABLE podnik_kategorie FROM nekurak;
915 GRANT ALL ON TABLE podnik_kategorie TO nekurak;
916 GRANT SELECT,INSERT,DELETE,UPDATE ON TABLE podnik_kategorie TO nekurak_web;
920 -- TOC entry 1974 (class 0 OID 0)
921 -- Dependencies: 1606
922 -- Name: role; Type: ACL; Schema: nekurak; Owner: nekurak
925 REVOKE ALL ON TABLE role FROM PUBLIC;
926 REVOKE ALL ON TABLE role FROM nekurak;
927 GRANT ALL ON TABLE role TO nekurak;
928 GRANT SELECT,INSERT,DELETE,UPDATE ON TABLE role TO nekurak_web;
932 -- TOC entry 1975 (class 0 OID 0)
933 -- Dependencies: 1604
934 -- Name: uzivatel_seq; Type: ACL; Schema: nekurak; Owner: nekurak
937 REVOKE ALL ON SEQUENCE uzivatel_seq FROM PUBLIC;
938 REVOKE ALL ON SEQUENCE uzivatel_seq FROM nekurak;
939 GRANT ALL ON SEQUENCE uzivatel_seq TO nekurak;
940 GRANT USAGE ON SEQUENCE uzivatel_seq TO nekurak_web;
944 -- TOC entry 1977 (class 0 OID 0)
945 -- Dependencies: 1605
946 -- Name: uzivatel; Type: ACL; Schema: nekurak; Owner: nekurak
949 REVOKE ALL ON TABLE uzivatel FROM PUBLIC;
950 REVOKE ALL ON TABLE uzivatel FROM nekurak;
951 GRANT ALL ON TABLE uzivatel TO nekurak;
952 GRANT SELECT,INSERT,DELETE,UPDATE ON TABLE uzivatel TO nekurak_web;
956 -- TOC entry 1979 (class 0 OID 0)
957 -- Dependencies: 1607
958 -- Name: uzivatel_role; Type: ACL; Schema: nekurak; Owner: nekurak
961 REVOKE ALL ON TABLE uzivatel_role FROM PUBLIC;
962 REVOKE ALL ON TABLE uzivatel_role FROM nekurak;
963 GRANT ALL ON TABLE uzivatel_role TO nekurak;
964 GRANT SELECT,INSERT,DELETE,UPDATE ON TABLE uzivatel_role TO nekurak_web;
967 -- Completed on 2011-01-15 14:24:31 CET
970 -- PostgreSQL database dump complete