2 -- PostgreSQL database dump
5 -- Started on 2011-01-11 15:26:21 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 1942 (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: 411 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 1943 (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 1610 (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 1609 (class 1259 OID 35205)
96 -- Dependencies: 1897 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 1945 (class 0 OID 0)
111 -- Dependencies: 1609
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 1607 (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 1608 (class 1259 OID 35185)
136 -- Dependencies: 1895 1896 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 1948 (class 0 OID 0)
152 -- Dependencies: 1608
153 -- Name: TABLE fotka; Type: COMMENT; Schema: nekurak; Owner: nekurak
156 COMMENT ON TABLE fotka IS 'Fotka podniku.';
160 -- TOC entry 1949 (class 0 OID 0)
161 -- Dependencies: 1608
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 1612 (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 1613 (class 1259 OID 35278)
185 -- Dependencies: 1898 1899 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 1952 (class 0 OID 0)
202 -- Dependencies: 1613
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 1953 (class 0 OID 0)
213 -- Dependencies: 1613
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 1616 (class 1259 OID 35396)
225 -- Name: kategorie_seq; Type: SEQUENCE; Schema: nekurak; Owner: nekurak
228 CREATE SEQUENCE kategorie_seq
235 ALTER TABLE nekurak.kategorie_seq OWNER TO nekurak;
238 -- TOC entry 1617 (class 1259 OID 35398)
239 -- Dependencies: 1902 10
240 -- Name: kategorie; Type: TABLE; Schema: nekurak; Owner: nekurak; Tablespace:
243 CREATE TABLE kategorie (
244 id integer DEFAULT nextval('kategorie_seq'::regclass) NOT NULL,
245 nazev character varying(32) NOT NULL
249 ALTER TABLE nekurak.kategorie OWNER TO nekurak;
252 -- TOC entry 1956 (class 0 OID 0)
253 -- Dependencies: 1617
254 -- Name: TABLE kategorie; Type: COMMENT; Schema: nekurak; Owner: nekurak
257 COMMENT ON TABLE kategorie IS 'Kategorie podniku';
261 -- TOC entry 1957 (class 0 OID 0)
262 -- Dependencies: 1617
263 -- Name: COLUMN kategorie.nazev; Type: COMMENT; Schema: nekurak; Owner: nekurak
266 COMMENT ON COLUMN kategorie.nazev IS 'jen pro info při přímé práci s SQL
267 aplikace bere názvy a popisy kategorií z lokalizačního souboru (na základě ID kategorie)';
271 -- TOC entry 1614 (class 1259 OID 35333)
273 -- Name: komentar_seq; Type: SEQUENCE; Schema: nekurak; Owner: nekurak
276 CREATE SEQUENCE komentar_seq
283 ALTER TABLE nekurak.komentar_seq OWNER TO nekurak;
286 -- TOC entry 1615 (class 1259 OID 35376)
287 -- Dependencies: 1900 1901 10
288 -- Name: komentar; Type: TABLE; Schema: nekurak; Owner: nekurak; Tablespace:
291 CREATE TABLE komentar (
292 id integer DEFAULT nextval('komentar_seq'::regclass) NOT NULL,
293 podnik integer NOT NULL,
294 uzivatel character varying(64) NOT NULL,
295 datum timestamp with time zone DEFAULT now() NOT NULL,
296 nadpis character varying(255),
297 komentar text NOT NULL
301 ALTER TABLE nekurak.komentar OWNER TO nekurak;
304 -- TOC entry 1960 (class 0 OID 0)
305 -- Dependencies: 1615
306 -- Name: TABLE komentar; Type: COMMENT; Schema: nekurak; Owner: nekurak
309 COMMENT ON TABLE komentar IS 'Komentář k podniku';
313 -- TOC entry 1961 (class 0 OID 0)
314 -- Dependencies: 1615
315 -- Name: COLUMN komentar.nadpis; Type: COMMENT; Schema: nekurak; Owner: nekurak
318 COMMENT ON COLUMN komentar.nadpis IS 'vždy jen prostý text';
322 -- TOC entry 1962 (class 0 OID 0)
323 -- Dependencies: 1615
324 -- Name: COLUMN komentar.komentar; Type: COMMENT; Schema: nekurak; Owner: nekurak
327 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.
328 Jedná se o kus validního XML – má kořenový element <div/>';
332 -- TOC entry 1601 (class 1259 OID 35019)
334 -- Name: podnik_seq; Type: SEQUENCE; Schema: nekurak; Owner: nekurak
337 CREATE SEQUENCE podnik_seq
344 ALTER TABLE nekurak.podnik_seq OWNER TO nekurak;
347 -- TOC entry 1602 (class 1259 OID 35049)
348 -- Dependencies: 1890 1891 1892 10
349 -- Name: podnik; Type: TABLE; Schema: nekurak; Owner: nekurak; Tablespace:
352 CREATE TABLE podnik (
353 id integer DEFAULT nextval('podnik_seq'::regclass) NOT NULL,
354 nazev character varying(255) NOT NULL,
355 popis character varying(255),
356 url character varying(255),
357 datum timestamp with time zone DEFAULT now(),
358 ulice character varying(64),
359 cislo_popisne integer,
360 mesto character varying(64),
361 spravce character varying(64),
362 sirka double precision,
363 delka double precision,
365 CONSTRAINT stav_tg CHECK (((stav = ANY (ARRAY['k'::bpchar, 'n'::bpchar, 'o'::bpchar, 'c'::bpchar])) OR (stav IS NULL)))
369 ALTER TABLE nekurak.podnik OWNER TO nekurak;
372 -- TOC entry 1965 (class 0 OID 0)
373 -- Dependencies: 1602
374 -- Name: COLUMN podnik.spravce; Type: COMMENT; Schema: nekurak; Owner: nekurak
377 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)';
381 -- TOC entry 1966 (class 0 OID 0)
382 -- Dependencies: 1602
383 -- Name: CONSTRAINT stav_tg ON podnik; Type: COMMENT; Schema: nekurak; Owner: nekurak
386 COMMENT ON CONSTRAINT stav_tg ON podnik IS 'k = kuřácký
388 o = oddělené části (důkladně)
389 c = částečně kuřácký (špatně oddělené, považujeme za kuřácký)
390 NULL = neznámý stav';
394 -- TOC entry 1618 (class 1259 OID 35404)
396 -- Name: podnik_kategorie; Type: TABLE; Schema: nekurak; Owner: nekurak; Tablespace:
399 CREATE TABLE podnik_kategorie (
400 podnik integer NOT NULL,
401 kategorie integer NOT NULL
405 ALTER TABLE nekurak.podnik_kategorie OWNER TO nekurak;
408 -- TOC entry 1605 (class 1259 OID 35101)
410 -- Name: role; Type: TABLE; Schema: nekurak; Owner: nekurak; Tablespace:
414 kod character varying(16) NOT NULL,
415 popis character varying(255)
419 ALTER TABLE nekurak.role OWNER TO nekurak;
422 -- TOC entry 1969 (class 0 OID 0)
423 -- Dependencies: 1605
424 -- Name: TABLE role; Type: COMMENT; Schema: nekurak; Owner: nekurak
427 COMMENT ON TABLE role IS 'Role (skupiny) uživatelů ~ oprávnění';
431 -- TOC entry 1603 (class 1259 OID 35080)
433 -- Name: uzivatel_seq; Type: SEQUENCE; Schema: nekurak; Owner: nekurak
436 CREATE SEQUENCE uzivatel_seq
443 ALTER TABLE nekurak.uzivatel_seq OWNER TO nekurak;
446 -- TOC entry 1604 (class 1259 OID 35091)
447 -- Dependencies: 1893 1894 10
448 -- Name: uzivatel; Type: TABLE; Schema: nekurak; Owner: nekurak; Tablespace:
451 CREATE TABLE uzivatel (
452 id integer DEFAULT nextval('uzivatel_seq'::regclass) NOT NULL,
453 prezdivka character varying(64) NOT NULL,
454 heslo character varying(512) NOT NULL,
455 jmeno character varying(64),
456 prijmeni character varying(64),
457 email character varying(255),
458 datum timestamp with time zone DEFAULT now() NOT NULL
462 ALTER TABLE nekurak.uzivatel OWNER TO nekurak;
465 -- TOC entry 1972 (class 0 OID 0)
466 -- Dependencies: 1604
467 -- Name: COLUMN uzivatel.prezdivka; Type: COMMENT; Schema: nekurak; Owner: nekurak
470 COMMENT ON COLUMN uzivatel.prezdivka IS 'Uživatelské jméno';
474 -- TOC entry 1606 (class 1259 OID 35106)
476 -- Name: uzivatel_role; Type: TABLE; Schema: nekurak; Owner: nekurak; Tablespace:
479 CREATE TABLE uzivatel_role (
480 role character varying(16) NOT NULL,
481 prezdivka character varying(64) NOT NULL
485 ALTER TABLE nekurak.uzivatel_role OWNER TO nekurak;
488 -- TOC entry 1974 (class 0 OID 0)
489 -- Dependencies: 1606
490 -- Name: TABLE uzivatel_role; Type: COMMENT; Schema: nekurak; Owner: nekurak
493 COMMENT ON TABLE uzivatel_role IS 'Přiřazení uživatelských rolí (skupin).';
497 -- TOC entry 1918 (class 2606 OID 35227)
498 -- Dependencies: 1609 1609
499 -- Name: clanek_pk; Type: CONSTRAINT; Schema: nekurak; Owner: nekurak; Tablespace:
502 ALTER TABLE ONLY clanek
503 ADD CONSTRAINT clanek_pk PRIMARY KEY (id);
507 -- TOC entry 1914 (class 2606 OID 35190)
508 -- Dependencies: 1608 1608
509 -- Name: fotka_pk; Type: CONSTRAINT; Schema: nekurak; Owner: nekurak; Tablespace:
512 ALTER TABLE ONLY fotka
513 ADD CONSTRAINT fotka_pk PRIMARY KEY (id);
517 -- TOC entry 1916 (class 2606 OID 35204)
518 -- Dependencies: 1608 1608 1608
519 -- Name: fotka_poradi_uq; Type: CONSTRAINT; Schema: nekurak; Owner: nekurak; Tablespace:
522 ALTER TABLE ONLY fotka
523 ADD CONSTRAINT fotka_poradi_uq UNIQUE (popis, poradi);
527 -- TOC entry 1921 (class 2606 OID 35284)
528 -- Dependencies: 1613 1613
529 -- Name: hlasovani_pk; Type: CONSTRAINT; Schema: nekurak; Owner: nekurak; Tablespace:
532 ALTER TABLE ONLY hlasovani
533 ADD CONSTRAINT hlasovani_pk PRIMARY KEY (id);
537 -- TOC entry 1926 (class 2606 OID 35403)
538 -- Dependencies: 1617 1617
539 -- Name: kategorie_pk; Type: CONSTRAINT; Schema: nekurak; Owner: nekurak; Tablespace:
542 ALTER TABLE ONLY kategorie
543 ADD CONSTRAINT kategorie_pk PRIMARY KEY (id);
547 -- TOC entry 1924 (class 2606 OID 35385)
548 -- Dependencies: 1615 1615
549 -- Name: komentar_pk; Type: CONSTRAINT; Schema: nekurak; Owner: nekurak; Tablespace:
552 ALTER TABLE ONLY komentar
553 ADD CONSTRAINT komentar_pk PRIMARY KEY (id);
557 -- TOC entry 1928 (class 2606 OID 35408)
558 -- Dependencies: 1618 1618 1618
559 -- Name: podnik_kategorie_pk; Type: CONSTRAINT; Schema: nekurak; Owner: nekurak; Tablespace:
562 ALTER TABLE ONLY podnik_kategorie
563 ADD CONSTRAINT podnik_kategorie_pk PRIMARY KEY (podnik, kategorie);
567 -- TOC entry 1904 (class 2606 OID 35058)
568 -- Dependencies: 1602 1602
569 -- Name: podnik_pk; Type: CONSTRAINT; Schema: nekurak; Owner: nekurak; Tablespace:
572 ALTER TABLE ONLY podnik
573 ADD CONSTRAINT podnik_pk PRIMARY KEY (id);
577 -- TOC entry 1910 (class 2606 OID 35105)
578 -- Dependencies: 1605 1605
579 -- Name: skupina_pk; Type: CONSTRAINT; Schema: nekurak; Owner: nekurak; Tablespace:
582 ALTER TABLE ONLY role
583 ADD CONSTRAINT skupina_pk PRIMARY KEY (kod);
587 -- TOC entry 1906 (class 2606 OID 35098)
588 -- Dependencies: 1604 1604
589 -- Name: uzivatel_pk; Type: CONSTRAINT; Schema: nekurak; Owner: nekurak; Tablespace:
592 ALTER TABLE ONLY uzivatel
593 ADD CONSTRAINT uzivatel_pk PRIMARY KEY (id);
597 -- TOC entry 1908 (class 2606 OID 35100)
598 -- Dependencies: 1604 1604
599 -- Name: uzivatel_prezdivka_uq; Type: CONSTRAINT; Schema: nekurak; Owner: nekurak; Tablespace:
602 ALTER TABLE ONLY uzivatel
603 ADD CONSTRAINT uzivatel_prezdivka_uq UNIQUE (prezdivka);
607 -- TOC entry 1912 (class 2606 OID 35137)
608 -- Dependencies: 1606 1606 1606
609 -- Name: uzivatel_role_pk; Type: CONSTRAINT; Schema: nekurak; Owner: nekurak; Tablespace:
612 ALTER TABLE ONLY uzivatel_role
613 ADD CONSTRAINT uzivatel_role_pk PRIMARY KEY (role, prezdivka);
617 -- TOC entry 1919 (class 1259 OID 35291)
618 -- Dependencies: 1613
619 -- Name: hlasovani_ip_idx; Type: INDEX; Schema: nekurak; Owner: nekurak; Tablespace:
622 CREATE INDEX hlasovani_ip_idx ON hlasovani USING btree (ip_adresa);
626 -- TOC entry 1922 (class 1259 OID 35309)
627 -- Dependencies: 1613
628 -- Name: hlsovani_datum_idx; Type: INDEX; Schema: nekurak; Owner: nekurak; Tablespace:
631 CREATE INDEX hlsovani_datum_idx ON hlasovani USING btree (date(datum));
635 -- TOC entry 1938 (class 2620 OID 35125)
636 -- Dependencies: 1604 65
637 -- Name: uzivatel_insert; Type: TRIGGER; Schema: nekurak; Owner: nekurak
640 CREATE TRIGGER uzivatel_insert
641 AFTER INSERT ON uzivatel
643 EXECUTE PROCEDURE bezny_uzivatel();
647 -- TOC entry 1932 (class 2606 OID 35191)
648 -- Dependencies: 1903 1608 1602
649 -- Name: fotka_podnik_fk; Type: FK CONSTRAINT; Schema: nekurak; Owner: nekurak
652 ALTER TABLE ONLY fotka
653 ADD CONSTRAINT fotka_podnik_fk FOREIGN KEY (podnik) REFERENCES podnik(id) ON DELETE CASCADE;
657 -- TOC entry 1933 (class 2606 OID 35285)
658 -- Dependencies: 1903 1602 1613
659 -- Name: hlasovani_podnik_fk; Type: FK CONSTRAINT; Schema: nekurak; Owner: nekurak
662 ALTER TABLE ONLY hlasovani
663 ADD CONSTRAINT hlasovani_podnik_fk FOREIGN KEY (podnik) REFERENCES podnik(id) ON DELETE CASCADE;
667 -- TOC entry 1934 (class 2606 OID 35386)
668 -- Dependencies: 1615 1602 1903
669 -- Name: komentar_podnik_fk; Type: FK CONSTRAINT; Schema: nekurak; Owner: nekurak
672 ALTER TABLE ONLY komentar
673 ADD CONSTRAINT komentar_podnik_fk FOREIGN KEY (podnik) REFERENCES podnik(id);
677 -- TOC entry 1935 (class 2606 OID 35391)
678 -- Dependencies: 1907 1604 1615
679 -- Name: komentar_uzivatel_fk; Type: FK CONSTRAINT; Schema: nekurak; Owner: nekurak
682 ALTER TABLE ONLY komentar
683 ADD CONSTRAINT komentar_uzivatel_fk FOREIGN KEY (uzivatel) REFERENCES uzivatel(prezdivka);
687 -- TOC entry 1937 (class 2606 OID 35414)
688 -- Dependencies: 1618 1925 1617
689 -- Name: podnik_kategorie_kategorie_fk; Type: FK CONSTRAINT; Schema: nekurak; Owner: nekurak
692 ALTER TABLE ONLY podnik_kategorie
693 ADD CONSTRAINT podnik_kategorie_kategorie_fk FOREIGN KEY (kategorie) REFERENCES kategorie(id) ON DELETE CASCADE;
697 -- TOC entry 1936 (class 2606 OID 35409)
698 -- Dependencies: 1903 1602 1618
699 -- Name: podnik_kategorie_podnik_fk; Type: FK CONSTRAINT; Schema: nekurak; Owner: nekurak
702 ALTER TABLE ONLY podnik_kategorie
703 ADD CONSTRAINT podnik_kategorie_podnik_fk FOREIGN KEY (podnik) REFERENCES podnik(id) ON DELETE CASCADE;
707 -- TOC entry 1929 (class 2606 OID 35178)
708 -- Dependencies: 1602 1604 1907
709 -- Name: podnik_uzivatel_fk; Type: FK CONSTRAINT; Schema: nekurak; Owner: nekurak
712 ALTER TABLE ONLY podnik
713 ADD CONSTRAINT podnik_uzivatel_fk FOREIGN KEY (spravce) REFERENCES uzivatel(prezdivka) ON DELETE SET NULL;
717 -- TOC entry 1930 (class 2606 OID 35138)
718 -- Dependencies: 1909 1606 1605
719 -- Name: uzivatel_role_role_fk; Type: FK CONSTRAINT; Schema: nekurak; Owner: nekurak
722 ALTER TABLE ONLY uzivatel_role
723 ADD CONSTRAINT uzivatel_role_role_fk FOREIGN KEY (role) REFERENCES role(kod) ON UPDATE CASCADE ON DELETE CASCADE;
727 -- TOC entry 1931 (class 2606 OID 35143)
728 -- Dependencies: 1907 1604 1606
729 -- Name: uzivatel_role_uzivatel_fk; Type: FK CONSTRAINT; Schema: nekurak; Owner: nekurak
732 ALTER TABLE ONLY uzivatel_role
733 ADD CONSTRAINT uzivatel_role_uzivatel_fk FOREIGN KEY (prezdivka) REFERENCES uzivatel(prezdivka) ON UPDATE CASCADE ON DELETE CASCADE;
737 -- TOC entry 1941 (class 0 OID 0)
739 -- Name: nekurak; Type: ACL; Schema: -; Owner: nekurak
742 REVOKE ALL ON SCHEMA nekurak FROM PUBLIC;
743 REVOKE ALL ON SCHEMA nekurak FROM nekurak;
744 GRANT ALL ON SCHEMA nekurak TO nekurak;
745 GRANT USAGE ON SCHEMA nekurak TO nekurak_web;
749 -- TOC entry 1944 (class 0 OID 0)
750 -- Dependencies: 1610
751 -- Name: clanek_seq; Type: ACL; Schema: nekurak; Owner: nekurak
754 REVOKE ALL ON SEQUENCE clanek_seq FROM PUBLIC;
755 REVOKE ALL ON SEQUENCE clanek_seq FROM nekurak;
756 GRANT ALL ON SEQUENCE clanek_seq TO nekurak;
757 GRANT USAGE ON SEQUENCE clanek_seq TO nekurak_web;
761 -- TOC entry 1946 (class 0 OID 0)
762 -- Dependencies: 1609
763 -- Name: clanek; Type: ACL; Schema: nekurak; Owner: nekurak
766 REVOKE ALL ON TABLE clanek FROM PUBLIC;
767 REVOKE ALL ON TABLE clanek FROM nekurak;
768 GRANT ALL ON TABLE clanek TO nekurak;
769 GRANT SELECT,INSERT,DELETE,UPDATE ON TABLE clanek TO nekurak_web;
773 -- TOC entry 1947 (class 0 OID 0)
774 -- Dependencies: 1607
775 -- Name: fotka_seq; Type: ACL; Schema: nekurak; Owner: nekurak
778 REVOKE ALL ON SEQUENCE fotka_seq FROM PUBLIC;
779 REVOKE ALL ON SEQUENCE fotka_seq FROM nekurak;
780 GRANT ALL ON SEQUENCE fotka_seq TO nekurak;
781 GRANT USAGE ON SEQUENCE fotka_seq TO nekurak_web;
785 -- TOC entry 1950 (class 0 OID 0)
786 -- Dependencies: 1608
787 -- Name: fotka; Type: ACL; Schema: nekurak; Owner: nekurak
790 REVOKE ALL ON TABLE fotka FROM PUBLIC;
791 REVOKE ALL ON TABLE fotka FROM nekurak;
792 GRANT ALL ON TABLE fotka TO nekurak;
793 GRANT SELECT,INSERT,DELETE,UPDATE ON TABLE fotka TO nekurak_web;
797 -- TOC entry 1951 (class 0 OID 0)
798 -- Dependencies: 1612
799 -- Name: hlasovani_seq; Type: ACL; Schema: nekurak; Owner: nekurak
802 REVOKE ALL ON SEQUENCE hlasovani_seq FROM PUBLIC;
803 REVOKE ALL ON SEQUENCE hlasovani_seq FROM nekurak;
804 GRANT ALL ON SEQUENCE hlasovani_seq TO nekurak;
805 GRANT USAGE ON SEQUENCE hlasovani_seq TO nekurak_web;
809 -- TOC entry 1954 (class 0 OID 0)
810 -- Dependencies: 1613
811 -- Name: hlasovani; Type: ACL; Schema: nekurak; Owner: nekurak
814 REVOKE ALL ON TABLE hlasovani FROM PUBLIC;
815 REVOKE ALL ON TABLE hlasovani FROM nekurak;
816 GRANT ALL ON TABLE hlasovani TO nekurak;
817 GRANT SELECT,INSERT ON TABLE hlasovani TO nekurak_web;
821 -- TOC entry 1955 (class 0 OID 0)
822 -- Dependencies: 1616
823 -- Name: kategorie_seq; Type: ACL; Schema: nekurak; Owner: nekurak
826 REVOKE ALL ON SEQUENCE kategorie_seq FROM PUBLIC;
827 REVOKE ALL ON SEQUENCE kategorie_seq FROM nekurak;
828 GRANT ALL ON SEQUENCE kategorie_seq TO nekurak;
829 GRANT USAGE ON SEQUENCE kategorie_seq TO nekurak_web;
833 -- TOC entry 1958 (class 0 OID 0)
834 -- Dependencies: 1617
835 -- Name: kategorie; Type: ACL; Schema: nekurak; Owner: nekurak
838 REVOKE ALL ON TABLE kategorie FROM PUBLIC;
839 REVOKE ALL ON TABLE kategorie FROM nekurak;
840 GRANT ALL ON TABLE kategorie TO nekurak;
841 GRANT SELECT,INSERT,DELETE,UPDATE ON TABLE kategorie TO nekurak_web;
845 -- TOC entry 1959 (class 0 OID 0)
846 -- Dependencies: 1614
847 -- Name: komentar_seq; Type: ACL; Schema: nekurak; Owner: nekurak
850 REVOKE ALL ON SEQUENCE komentar_seq FROM PUBLIC;
851 REVOKE ALL ON SEQUENCE komentar_seq FROM nekurak;
852 GRANT ALL ON SEQUENCE komentar_seq TO nekurak;
853 GRANT USAGE ON SEQUENCE komentar_seq TO nekurak_web;
857 -- TOC entry 1963 (class 0 OID 0)
858 -- Dependencies: 1615
859 -- Name: komentar; Type: ACL; Schema: nekurak; Owner: nekurak
862 REVOKE ALL ON TABLE komentar FROM PUBLIC;
863 REVOKE ALL ON TABLE komentar FROM nekurak;
864 GRANT ALL ON TABLE komentar TO nekurak;
865 GRANT SELECT,INSERT ON TABLE komentar TO nekurak_web;
869 -- TOC entry 1964 (class 0 OID 0)
870 -- Dependencies: 1601
871 -- Name: podnik_seq; Type: ACL; Schema: nekurak; Owner: nekurak
874 REVOKE ALL ON SEQUENCE podnik_seq FROM PUBLIC;
875 REVOKE ALL ON SEQUENCE podnik_seq FROM nekurak;
876 GRANT ALL ON SEQUENCE podnik_seq TO nekurak;
877 GRANT USAGE ON SEQUENCE podnik_seq TO nekurak_web;
881 -- TOC entry 1967 (class 0 OID 0)
882 -- Dependencies: 1602
883 -- Name: podnik; Type: ACL; Schema: nekurak; Owner: nekurak
886 REVOKE ALL ON TABLE podnik FROM PUBLIC;
887 REVOKE ALL ON TABLE podnik FROM nekurak;
888 GRANT ALL ON TABLE podnik TO nekurak;
889 GRANT SELECT,INSERT,DELETE,UPDATE ON TABLE podnik TO nekurak_web;
893 -- TOC entry 1968 (class 0 OID 0)
894 -- Dependencies: 1618
895 -- Name: podnik_kategorie; Type: ACL; Schema: nekurak; Owner: nekurak
898 REVOKE ALL ON TABLE podnik_kategorie FROM PUBLIC;
899 REVOKE ALL ON TABLE podnik_kategorie FROM nekurak;
900 GRANT ALL ON TABLE podnik_kategorie TO nekurak;
901 GRANT SELECT,INSERT,DELETE,UPDATE ON TABLE podnik_kategorie TO nekurak_web;
905 -- TOC entry 1970 (class 0 OID 0)
906 -- Dependencies: 1605
907 -- Name: role; Type: ACL; Schema: nekurak; Owner: nekurak
910 REVOKE ALL ON TABLE role FROM PUBLIC;
911 REVOKE ALL ON TABLE role FROM nekurak;
912 GRANT ALL ON TABLE role TO nekurak;
913 GRANT SELECT,INSERT,DELETE,UPDATE ON TABLE role TO nekurak_web;
917 -- TOC entry 1971 (class 0 OID 0)
918 -- Dependencies: 1603
919 -- Name: uzivatel_seq; Type: ACL; Schema: nekurak; Owner: nekurak
922 REVOKE ALL ON SEQUENCE uzivatel_seq FROM PUBLIC;
923 REVOKE ALL ON SEQUENCE uzivatel_seq FROM nekurak;
924 GRANT ALL ON SEQUENCE uzivatel_seq TO nekurak;
925 GRANT USAGE ON SEQUENCE uzivatel_seq TO nekurak_web;
929 -- TOC entry 1973 (class 0 OID 0)
930 -- Dependencies: 1604
931 -- Name: uzivatel; Type: ACL; Schema: nekurak; Owner: nekurak
934 REVOKE ALL ON TABLE uzivatel FROM PUBLIC;
935 REVOKE ALL ON TABLE uzivatel FROM nekurak;
936 GRANT ALL ON TABLE uzivatel TO nekurak;
937 GRANT SELECT,INSERT,DELETE,UPDATE ON TABLE uzivatel TO nekurak_web;
941 -- TOC entry 1975 (class 0 OID 0)
942 -- Dependencies: 1606
943 -- Name: uzivatel_role; Type: ACL; Schema: nekurak; Owner: nekurak
946 REVOKE ALL ON TABLE uzivatel_role FROM PUBLIC;
947 REVOKE ALL ON TABLE uzivatel_role FROM nekurak;
948 GRANT ALL ON TABLE uzivatel_role TO nekurak;
949 GRANT SELECT,INSERT,DELETE,UPDATE ON TABLE uzivatel_role TO nekurak_web;
952 -- Completed on 2011-01-11 15:26:23 CET
955 -- PostgreSQL database dump complete