[1255] | 1 | -- |
---|
| 2 | -- PostgreSQL database dump |
---|
| 3 | -- |
---|
| 4 | |
---|
| 5 | SET client_encoding = 'LATIN1'; |
---|
| 6 | SET standard_conforming_strings = off; |
---|
| 7 | SET check_function_bodies = false; |
---|
| 8 | SET client_min_messages = warning; |
---|
| 9 | SET escape_string_warning = off; |
---|
| 10 | |
---|
| 11 | -- |
---|
| 12 | -- Name: workflow; Type: DATABASE; Schema: -; Owner: postgres |
---|
| 13 | -- |
---|
| 14 | |
---|
| 15 | CREATE DATABASE workflow WITH TEMPLATE = template0 ENCODING = 'LATIN1'; |
---|
| 16 | |
---|
| 17 | |
---|
| 18 | ALTER DATABASE workflow OWNER TO postgres; |
---|
| 19 | |
---|
| 20 | CREATE USER admin_workflow WITH PASSWORD 'admin_workflow' NOCREATEDB NOCREATEUSER VALID UNTIL 'infinity'; |
---|
| 21 | CREATE GROUP workflow; |
---|
| 22 | ALTER GROUP workflow ADD USER admin_workflow; |
---|
| 23 | GRANT workflow TO admin_workflow; |
---|
| 24 | CREATE USER admin_cds WITH PASSWORD 'admin_cds' NOCREATEDB NOCREATEUSER VALID UNTIL 'infinity'; |
---|
| 25 | ALTER GROUP workflow ADD USER admin_cds; |
---|
| 26 | GRANT workflow TO admin_cds; |
---|
| 27 | |
---|
| 28 | \connect workflow |
---|
| 29 | |
---|
| 30 | SET client_encoding = 'LATIN1'; |
---|
| 31 | SET standard_conforming_strings = off; |
---|
| 32 | SET check_function_bodies = false; |
---|
| 33 | SET client_min_messages = warning; |
---|
| 34 | SET escape_string_warning = off; |
---|
| 35 | |
---|
| 36 | -- |
---|
| 37 | -- Name: cds; Type: SCHEMA; Schema: -; Owner: admin_cds |
---|
| 38 | -- |
---|
| 39 | |
---|
| 40 | CREATE SCHEMA cds; |
---|
| 41 | |
---|
| 42 | |
---|
| 43 | ALTER SCHEMA cds OWNER TO admin_cds; |
---|
| 44 | |
---|
| 45 | SET search_path = cds, pg_catalog; |
---|
| 46 | |
---|
| 47 | SET default_tablespace = ''; |
---|
| 48 | |
---|
| 49 | SET default_with_oids = false; |
---|
| 50 | |
---|
| 51 | -- |
---|
| 52 | -- Name: cdcollection; Type: TABLE; Schema: cds; Owner: admin_cds; Tablespace: |
---|
| 53 | -- |
---|
| 54 | |
---|
| 55 | CREATE TABLE cdcollection ( |
---|
| 56 | cdid integer NOT NULL, |
---|
| 57 | title character varying(200), |
---|
| 58 | status character varying(40), |
---|
| 59 | usuario character varying(200) |
---|
| 60 | ); |
---|
| 61 | |
---|
| 62 | |
---|
| 63 | ALTER TABLE cds.cdcollection OWNER TO admin_cds; |
---|
| 64 | |
---|
| 65 | -- |
---|
| 66 | -- Name: TABLE cdcollection; Type: COMMENT; Schema: cds; Owner: admin_cds |
---|
| 67 | -- |
---|
| 68 | |
---|
| 69 | COMMENT ON TABLE cdcollection IS 'Exemplo de Empréstimo de CDs'; |
---|
| 70 | |
---|
| 71 | |
---|
| 72 | SET search_path = public, pg_catalog; |
---|
| 73 | |
---|
| 74 | -- |
---|
| 75 | -- Name: area; Type: TABLE; Schema: public; Owner: postgres; Tablespace: |
---|
| 76 | -- |
---|
| 77 | |
---|
| 78 | CREATE TABLE area ( |
---|
| 79 | organizacao_id integer NOT NULL, |
---|
| 80 | area_id integer NOT NULL, |
---|
| 81 | area_status_id integer NOT NULL, |
---|
| 82 | areasup_organizacao_id integer, |
---|
| 83 | superior_area_id integer, |
---|
| 84 | centro_custo_id integer, |
---|
| 85 | titular_funcionario_id integer, |
---|
| 86 | substituto_funcionario_id integer, |
---|
| 87 | sigla character varying(20) NOT NULL, |
---|
| 88 | descricao character varying(100) NOT NULL, |
---|
| 89 | ativa character varying(1) NOT NULL, |
---|
| 90 | auxiliar_funcionario_id integer |
---|
| 91 | ); |
---|
| 92 | |
---|
| 93 | |
---|
| 94 | ALTER TABLE public.area OWNER TO postgres; |
---|
| 95 | |
---|
| 96 | -- |
---|
| 97 | -- Name: area_area_id_seq; Type: SEQUENCE; Schema: public; Owner: postgres |
---|
| 98 | -- |
---|
| 99 | |
---|
| 100 | CREATE SEQUENCE area_area_id_seq |
---|
| 101 | START WITH 1 |
---|
| 102 | INCREMENT BY 1 |
---|
| 103 | NO MAXVALUE |
---|
| 104 | NO MINVALUE |
---|
| 105 | CACHE 1; |
---|
| 106 | |
---|
| 107 | |
---|
| 108 | ALTER TABLE public.area_area_id_seq OWNER TO postgres; |
---|
| 109 | |
---|
| 110 | -- |
---|
| 111 | -- Name: area_area_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: postgres |
---|
| 112 | -- |
---|
| 113 | |
---|
| 114 | ALTER SEQUENCE area_area_id_seq OWNED BY area.area_id; |
---|
| 115 | |
---|
| 116 | |
---|
| 117 | -- |
---|
| 118 | -- Name: area_area_id_seq; Type: SEQUENCE SET; Schema: public; Owner: postgres |
---|
| 119 | -- |
---|
| 120 | |
---|
| 121 | SELECT pg_catalog.setval('area_area_id_seq', 1, false); |
---|
| 122 | |
---|
| 123 | |
---|
| 124 | -- |
---|
| 125 | -- Name: area_status; Type: TABLE; Schema: public; Owner: postgres; Tablespace: |
---|
| 126 | -- |
---|
| 127 | |
---|
| 128 | CREATE TABLE area_status ( |
---|
| 129 | area_status_id integer NOT NULL, |
---|
| 130 | organizacao_id integer NOT NULL, |
---|
| 131 | descricao character varying(50) NOT NULL, |
---|
| 132 | nivel integer NOT NULL |
---|
| 133 | ); |
---|
| 134 | |
---|
| 135 | |
---|
| 136 | ALTER TABLE public.area_status OWNER TO postgres; |
---|
| 137 | |
---|
| 138 | -- |
---|
| 139 | -- Name: area_status_area_status_id_seq; Type: SEQUENCE; Schema: public; Owner: postgres |
---|
| 140 | -- |
---|
| 141 | |
---|
| 142 | CREATE SEQUENCE area_status_area_status_id_seq |
---|
| 143 | START WITH 1 |
---|
| 144 | INCREMENT BY 1 |
---|
| 145 | NO MAXVALUE |
---|
| 146 | NO MINVALUE |
---|
| 147 | CACHE 1; |
---|
| 148 | |
---|
| 149 | |
---|
| 150 | ALTER TABLE public.area_status_area_status_id_seq OWNER TO postgres; |
---|
| 151 | |
---|
| 152 | -- |
---|
| 153 | -- Name: area_status_area_status_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: postgres |
---|
| 154 | -- |
---|
| 155 | |
---|
| 156 | ALTER SEQUENCE area_status_area_status_id_seq OWNED BY area_status.area_status_id; |
---|
| 157 | |
---|
| 158 | |
---|
| 159 | -- |
---|
| 160 | -- Name: area_status_area_status_id_seq; Type: SEQUENCE SET; Schema: public; Owner: postgres |
---|
| 161 | -- |
---|
| 162 | |
---|
| 163 | SELECT pg_catalog.setval('area_status_area_status_id_seq', 1, false); |
---|
| 164 | |
---|
| 165 | |
---|
| 166 | -- |
---|
| 167 | -- Name: cargo; Type: TABLE; Schema: public; Owner: postgres; Tablespace: |
---|
| 168 | -- |
---|
| 169 | |
---|
| 170 | CREATE TABLE cargo ( |
---|
| 171 | cargo_id integer NOT NULL, |
---|
| 172 | descricao character varying(150), |
---|
| 173 | organizacao_id integer |
---|
| 174 | ); |
---|
| 175 | |
---|
| 176 | |
---|
| 177 | ALTER TABLE public.cargo OWNER TO postgres; |
---|
| 178 | |
---|
| 179 | -- |
---|
| 180 | -- Name: cargo_cargo_id_seq; Type: SEQUENCE; Schema: public; Owner: postgres |
---|
| 181 | -- |
---|
| 182 | |
---|
| 183 | CREATE SEQUENCE cargo_cargo_id_seq |
---|
| 184 | START WITH 1 |
---|
| 185 | INCREMENT BY 1 |
---|
| 186 | NO MAXVALUE |
---|
| 187 | NO MINVALUE |
---|
| 188 | CACHE 1; |
---|
| 189 | |
---|
| 190 | |
---|
| 191 | ALTER TABLE public.cargo_cargo_id_seq OWNER TO postgres; |
---|
| 192 | |
---|
| 193 | -- |
---|
| 194 | -- Name: cargo_cargo_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: postgres |
---|
| 195 | -- |
---|
| 196 | |
---|
| 197 | ALTER SEQUENCE cargo_cargo_id_seq OWNED BY cargo.cargo_id; |
---|
| 198 | |
---|
| 199 | |
---|
| 200 | -- |
---|
| 201 | -- Name: cargo_cargo_id_seq; Type: SEQUENCE SET; Schema: public; Owner: postgres |
---|
| 202 | -- |
---|
| 203 | |
---|
| 204 | SELECT pg_catalog.setval('cargo_cargo_id_seq', 1, false); |
---|
| 205 | |
---|
| 206 | |
---|
| 207 | -- |
---|
| 208 | -- Name: centro_custo; Type: TABLE; Schema: public; Owner: postgres; Tablespace: |
---|
| 209 | -- |
---|
| 210 | |
---|
| 211 | CREATE TABLE centro_custo ( |
---|
| 212 | organizacao_id integer NOT NULL, |
---|
| 213 | centro_custo_id integer NOT NULL, |
---|
| 214 | nm_centro_custo integer NOT NULL, |
---|
| 215 | grupo character varying(30), |
---|
| 216 | descricao character varying(100) NOT NULL |
---|
| 217 | ); |
---|
| 218 | |
---|
| 219 | |
---|
| 220 | ALTER TABLE public.centro_custo OWNER TO postgres; |
---|
| 221 | |
---|
| 222 | -- |
---|
| 223 | -- Name: centro_custo_centro_custo_id_seq; Type: SEQUENCE; Schema: public; Owner: postgres |
---|
| 224 | -- |
---|
| 225 | |
---|
| 226 | CREATE SEQUENCE centro_custo_centro_custo_id_seq |
---|
| 227 | START WITH 1 |
---|
| 228 | INCREMENT BY 1 |
---|
| 229 | NO MAXVALUE |
---|
| 230 | NO MINVALUE |
---|
| 231 | CACHE 1; |
---|
| 232 | |
---|
| 233 | |
---|
| 234 | ALTER TABLE public.centro_custo_centro_custo_id_seq OWNER TO postgres; |
---|
| 235 | |
---|
| 236 | -- |
---|
| 237 | -- Name: centro_custo_centro_custo_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: postgres |
---|
| 238 | -- |
---|
| 239 | |
---|
| 240 | ALTER SEQUENCE centro_custo_centro_custo_id_seq OWNED BY centro_custo.centro_custo_id; |
---|
| 241 | |
---|
| 242 | |
---|
| 243 | -- |
---|
| 244 | -- Name: centro_custo_centro_custo_id_seq; Type: SEQUENCE SET; Schema: public; Owner: postgres |
---|
| 245 | -- |
---|
| 246 | |
---|
| 247 | SELECT pg_catalog.setval('centro_custo_centro_custo_id_seq', 1, false); |
---|
| 248 | |
---|
| 249 | |
---|
| 250 | -- |
---|
| 251 | -- Name: funcionario; Type: TABLE; Schema: public; Owner: postgres; Tablespace: |
---|
| 252 | -- |
---|
| 253 | |
---|
| 254 | CREATE TABLE funcionario ( |
---|
| 255 | funcionario_id integer NOT NULL, |
---|
| 256 | area_id integer NOT NULL, |
---|
| 257 | localidade_id integer NOT NULL, |
---|
| 258 | centro_custo_id integer, |
---|
| 259 | organizacao_id integer NOT NULL, |
---|
| 260 | funcionario_status_id integer NOT NULL, |
---|
| 261 | cargo_id integer, |
---|
| 262 | nivel smallint, |
---|
| 263 | funcionario_categoria_id integer |
---|
| 264 | ); |
---|
| 265 | |
---|
| 266 | |
---|
| 267 | ALTER TABLE public.funcionario OWNER TO postgres; |
---|
| 268 | |
---|
| 269 | -- |
---|
| 270 | -- Name: funcionario_categoria; Type: TABLE; Schema: public; Owner: postgres; Tablespace: |
---|
| 271 | -- |
---|
| 272 | |
---|
| 273 | CREATE TABLE funcionario_categoria ( |
---|
| 274 | funcionario_categoria_id integer NOT NULL, |
---|
| 275 | descricao character varying(150), |
---|
| 276 | organizacao_id integer |
---|
| 277 | ); |
---|
| 278 | |
---|
| 279 | |
---|
| 280 | ALTER TABLE public.funcionario_categoria OWNER TO postgres; |
---|
| 281 | |
---|
| 282 | -- |
---|
| 283 | -- Name: funcionario_categoria_funcionario_categoria_id_seq; Type: SEQUENCE; Schema: public; Owner: postgres |
---|
| 284 | -- |
---|
| 285 | |
---|
| 286 | CREATE SEQUENCE funcionario_categoria_funcionario_categoria_id_seq |
---|
| 287 | START WITH 1 |
---|
| 288 | INCREMENT BY 1 |
---|
| 289 | NO MAXVALUE |
---|
| 290 | NO MINVALUE |
---|
| 291 | CACHE 1; |
---|
| 292 | |
---|
| 293 | |
---|
| 294 | ALTER TABLE public.funcionario_categoria_funcionario_categoria_id_seq OWNER TO postgres; |
---|
| 295 | |
---|
| 296 | -- |
---|
| 297 | -- Name: funcionario_categoria_funcionario_categoria_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: postgres |
---|
| 298 | -- |
---|
| 299 | |
---|
| 300 | ALTER SEQUENCE funcionario_categoria_funcionario_categoria_id_seq OWNED BY funcionario_categoria.funcionario_categoria_id; |
---|
| 301 | |
---|
| 302 | |
---|
| 303 | -- |
---|
| 304 | -- Name: funcionario_categoria_funcionario_categoria_id_seq; Type: SEQUENCE SET; Schema: public; Owner: postgres |
---|
| 305 | -- |
---|
| 306 | |
---|
| 307 | SELECT pg_catalog.setval('funcionario_categoria_funcionario_categoria_id_seq', 1, false); |
---|
| 308 | |
---|
| 309 | |
---|
| 310 | -- |
---|
| 311 | -- Name: funcionario_status; Type: TABLE; Schema: public; Owner: postgres; Tablespace: |
---|
| 312 | -- |
---|
| 313 | |
---|
| 314 | CREATE TABLE funcionario_status ( |
---|
| 315 | funcionario_status_id integer NOT NULL, |
---|
| 316 | descricao character varying(50) NOT NULL, |
---|
| 317 | exibir character varying(1) NOT NULL, |
---|
| 318 | organizacao_id integer NOT NULL |
---|
| 319 | ); |
---|
| 320 | |
---|
| 321 | |
---|
| 322 | ALTER TABLE public.funcionario_status OWNER TO postgres; |
---|
| 323 | |
---|
| 324 | -- |
---|
| 325 | -- Name: funcionario_status_funcionario_status_id_seq; Type: SEQUENCE; Schema: public; Owner: postgres |
---|
| 326 | -- |
---|
| 327 | |
---|
| 328 | CREATE SEQUENCE funcionario_status_funcionario_status_id_seq |
---|
| 329 | START WITH 1 |
---|
| 330 | INCREMENT BY 1 |
---|
| 331 | NO MAXVALUE |
---|
| 332 | NO MINVALUE |
---|
| 333 | CACHE 1; |
---|
| 334 | |
---|
| 335 | |
---|
| 336 | ALTER TABLE public.funcionario_status_funcionario_status_id_seq OWNER TO postgres; |
---|
| 337 | |
---|
| 338 | -- |
---|
| 339 | -- Name: funcionario_status_funcionario_status_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: postgres |
---|
| 340 | -- |
---|
| 341 | |
---|
| 342 | ALTER SEQUENCE funcionario_status_funcionario_status_id_seq OWNED BY funcionario_status.funcionario_status_id; |
---|
| 343 | |
---|
| 344 | |
---|
| 345 | -- |
---|
| 346 | -- Name: funcionario_status_funcionario_status_id_seq; Type: SEQUENCE SET; Schema: public; Owner: postgres |
---|
| 347 | -- |
---|
| 348 | |
---|
| 349 | SELECT pg_catalog.setval('funcionario_status_funcionario_status_id_seq', 1, false); |
---|
| 350 | |
---|
| 351 | |
---|
| 352 | -- |
---|
| 353 | -- Name: localidade; Type: TABLE; Schema: public; Owner: postgres; Tablespace: |
---|
| 354 | -- |
---|
| 355 | |
---|
| 356 | CREATE TABLE localidade ( |
---|
| 357 | organizacao_id integer NOT NULL, |
---|
| 358 | localidade_id integer NOT NULL, |
---|
| 359 | centro_custo_id integer, |
---|
| 360 | descricao character varying(50) NOT NULL |
---|
| 361 | ); |
---|
| 362 | |
---|
| 363 | |
---|
| 364 | ALTER TABLE public.localidade OWNER TO postgres; |
---|
| 365 | |
---|
| 366 | -- |
---|
| 367 | -- Name: localidade_localidade_id_seq; Type: SEQUENCE; Schema: public; Owner: postgres |
---|
| 368 | -- |
---|
| 369 | |
---|
| 370 | CREATE SEQUENCE localidade_localidade_id_seq |
---|
| 371 | START WITH 1 |
---|
| 372 | INCREMENT BY 1 |
---|
| 373 | NO MAXVALUE |
---|
| 374 | NO MINVALUE |
---|
| 375 | CACHE 1; |
---|
| 376 | |
---|
| 377 | |
---|
| 378 | ALTER TABLE public.localidade_localidade_id_seq OWNER TO postgres; |
---|
| 379 | |
---|
| 380 | -- |
---|
| 381 | -- Name: localidade_localidade_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: postgres |
---|
| 382 | -- |
---|
| 383 | |
---|
| 384 | ALTER SEQUENCE localidade_localidade_id_seq OWNED BY localidade.localidade_id; |
---|
| 385 | |
---|
| 386 | |
---|
| 387 | -- |
---|
| 388 | -- Name: localidade_localidade_id_seq; Type: SEQUENCE SET; Schema: public; Owner: postgres |
---|
| 389 | -- |
---|
| 390 | |
---|
| 391 | SELECT pg_catalog.setval('localidade_localidade_id_seq', 1, false); |
---|
| 392 | |
---|
| 393 | |
---|
| 394 | -- |
---|
| 395 | -- Name: organizacao; Type: TABLE; Schema: public; Owner: postgres; Tablespace: |
---|
| 396 | -- |
---|
| 397 | |
---|
| 398 | CREATE TABLE organizacao ( |
---|
| 399 | organizacao_id integer NOT NULL, |
---|
| 400 | nome character varying(20) NOT NULL, |
---|
| 401 | descricao character varying(100) NOT NULL, |
---|
| 402 | url_imagem character varying(200), |
---|
| 403 | ativa character varying(1) NOT NULL |
---|
| 404 | ); |
---|
| 405 | |
---|
| 406 | |
---|
| 407 | ALTER TABLE public.organizacao OWNER TO postgres; |
---|
| 408 | |
---|
| 409 | -- |
---|
| 410 | -- Name: organizacao_organizacao_id_seq; Type: SEQUENCE; Schema: public; Owner: postgres |
---|
| 411 | -- |
---|
| 412 | |
---|
| 413 | CREATE SEQUENCE organizacao_organizacao_id_seq |
---|
| 414 | START WITH 1 |
---|
| 415 | INCREMENT BY 1 |
---|
| 416 | NO MAXVALUE |
---|
| 417 | NO MINVALUE |
---|
| 418 | CACHE 1; |
---|
| 419 | |
---|
| 420 | |
---|
| 421 | ALTER TABLE public.organizacao_organizacao_id_seq OWNER TO postgres; |
---|
| 422 | |
---|
| 423 | -- |
---|
| 424 | -- Name: organizacao_organizacao_id_seq; Type: SEQUENCE OWNED BY; Schema: public; Owner: postgres |
---|
| 425 | -- |
---|
| 426 | |
---|
| 427 | ALTER SEQUENCE organizacao_organizacao_id_seq OWNED BY organizacao.organizacao_id; |
---|
| 428 | |
---|
| 429 | |
---|
| 430 | -- |
---|
| 431 | -- Name: organizacao_organizacao_id_seq; Type: SEQUENCE SET; Schema: public; Owner: postgres |
---|
| 432 | -- |
---|
| 433 | |
---|
| 434 | SELECT pg_catalog.setval('organizacao_organizacao_id_seq', 1, false); |
---|
| 435 | |
---|
| 436 | |
---|
| 437 | -- |
---|
| 438 | -- Name: area_id; Type: DEFAULT; Schema: public; Owner: postgres |
---|
| 439 | -- |
---|
| 440 | |
---|
| 441 | ALTER TABLE area ALTER COLUMN area_id SET DEFAULT nextval('area_area_id_seq'::regclass); |
---|
| 442 | |
---|
| 443 | |
---|
| 444 | -- |
---|
| 445 | -- Name: area_status_id; Type: DEFAULT; Schema: public; Owner: postgres |
---|
| 446 | -- |
---|
| 447 | |
---|
| 448 | ALTER TABLE area_status ALTER COLUMN area_status_id SET DEFAULT nextval('area_status_area_status_id_seq'::regclass); |
---|
| 449 | |
---|
| 450 | |
---|
| 451 | -- |
---|
| 452 | -- Name: cargo_id; Type: DEFAULT; Schema: public; Owner: postgres |
---|
| 453 | -- |
---|
| 454 | |
---|
| 455 | ALTER TABLE cargo ALTER COLUMN cargo_id SET DEFAULT nextval('cargo_cargo_id_seq'::regclass); |
---|
| 456 | |
---|
| 457 | |
---|
| 458 | -- |
---|
| 459 | -- Name: centro_custo_id; Type: DEFAULT; Schema: public; Owner: postgres |
---|
| 460 | -- |
---|
| 461 | |
---|
| 462 | ALTER TABLE centro_custo ALTER COLUMN centro_custo_id SET DEFAULT nextval('centro_custo_centro_custo_id_seq'::regclass); |
---|
| 463 | |
---|
| 464 | |
---|
| 465 | -- |
---|
| 466 | -- Name: funcionario_categoria_id; Type: DEFAULT; Schema: public; Owner: postgres |
---|
| 467 | -- |
---|
| 468 | |
---|
| 469 | ALTER TABLE funcionario_categoria ALTER COLUMN funcionario_categoria_id SET DEFAULT nextval('funcionario_categoria_funcionario_categoria_id_seq'::regclass); |
---|
| 470 | |
---|
| 471 | |
---|
| 472 | -- |
---|
| 473 | -- Name: funcionario_status_id; Type: DEFAULT; Schema: public; Owner: postgres |
---|
| 474 | -- |
---|
| 475 | |
---|
| 476 | ALTER TABLE funcionario_status ALTER COLUMN funcionario_status_id SET DEFAULT nextval('funcionario_status_funcionario_status_id_seq'::regclass); |
---|
| 477 | |
---|
| 478 | |
---|
| 479 | -- |
---|
| 480 | -- Name: localidade_id; Type: DEFAULT; Schema: public; Owner: postgres |
---|
| 481 | -- |
---|
| 482 | |
---|
| 483 | ALTER TABLE localidade ALTER COLUMN localidade_id SET DEFAULT nextval('localidade_localidade_id_seq'::regclass); |
---|
| 484 | |
---|
| 485 | |
---|
| 486 | -- |
---|
| 487 | -- Name: organizacao_id; Type: DEFAULT; Schema: public; Owner: postgres |
---|
| 488 | -- |
---|
| 489 | |
---|
| 490 | ALTER TABLE organizacao ALTER COLUMN organizacao_id SET DEFAULT nextval('organizacao_organizacao_id_seq'::regclass); |
---|
| 491 | |
---|
| 492 | |
---|
| 493 | SET search_path = cds, pg_catalog; |
---|
| 494 | |
---|
| 495 | -- |
---|
| 496 | -- Data for Name: cdcollection; Type: TABLE DATA; Schema: cds; Owner: admin_cds |
---|
| 497 | -- |
---|
| 498 | |
---|
| 499 | INSERT INTO cdcollection VALUES (1, 'Compact Disc 1', 'disponivel', NULL); |
---|
| 500 | INSERT INTO cdcollection VALUES (2, 'Compact Disc 2', 'disponivel', NULL); |
---|
| 501 | INSERT INTO cdcollection VALUES (3, 'Compact Disc 3', 'disponivel', NULL); |
---|
| 502 | |
---|
| 503 | |
---|
| 504 | SET search_path = cds, pg_catalog; |
---|
| 505 | |
---|
| 506 | -- |
---|
| 507 | -- Name: cdcollection_pkey; Type: CONSTRAINT; Schema: cds; Owner: admin_cds; Tablespace: |
---|
| 508 | -- |
---|
| 509 | |
---|
| 510 | ALTER TABLE ONLY cdcollection |
---|
| 511 | ADD CONSTRAINT cdcollection_pkey PRIMARY KEY (cdid); |
---|
| 512 | |
---|
| 513 | |
---|
| 514 | SET search_path = public, pg_catalog; |
---|
| 515 | |
---|
| 516 | -- |
---|
| 517 | -- Name: area_pkey; Type: CONSTRAINT; Schema: public; Owner: postgres; Tablespace: |
---|
| 518 | -- |
---|
| 519 | |
---|
| 520 | ALTER TABLE ONLY area |
---|
| 521 | ADD CONSTRAINT area_pkey PRIMARY KEY (organizacao_id, area_id); |
---|
| 522 | |
---|
| 523 | |
---|
| 524 | -- |
---|
| 525 | -- Name: areastatus_pkey; Type: CONSTRAINT; Schema: public; Owner: postgres; Tablespace: |
---|
| 526 | -- |
---|
| 527 | |
---|
| 528 | ALTER TABLE ONLY area_status |
---|
| 529 | ADD CONSTRAINT areastatus_pkey PRIMARY KEY (area_status_id, organizacao_id); |
---|
| 530 | |
---|
| 531 | |
---|
| 532 | -- |
---|
| 533 | -- Name: centrocusto_pkey; Type: CONSTRAINT; Schema: public; Owner: postgres; Tablespace: |
---|
| 534 | -- |
---|
| 535 | |
---|
| 536 | ALTER TABLE ONLY centro_custo |
---|
| 537 | ADD CONSTRAINT centrocusto_pkey PRIMARY KEY (organizacao_id, centro_custo_id); |
---|
| 538 | |
---|
| 539 | |
---|
| 540 | -- |
---|
| 541 | -- Name: funcionario_pkey; Type: CONSTRAINT; Schema: public; Owner: postgres; Tablespace: |
---|
| 542 | -- |
---|
| 543 | |
---|
| 544 | ALTER TABLE ONLY funcionario |
---|
| 545 | ADD CONSTRAINT funcionario_pkey PRIMARY KEY (funcionario_id); |
---|
| 546 | |
---|
| 547 | |
---|
| 548 | -- |
---|
| 549 | -- Name: funcionario_status_pkey; Type: CONSTRAINT; Schema: public; Owner: postgres; Tablespace: |
---|
| 550 | -- |
---|
| 551 | |
---|
| 552 | ALTER TABLE ONLY funcionario_status |
---|
| 553 | ADD CONSTRAINT funcionario_status_pkey PRIMARY KEY (funcionario_status_id); |
---|
| 554 | |
---|
| 555 | |
---|
| 556 | -- |
---|
| 557 | -- Name: localidade_pkey; Type: CONSTRAINT; Schema: public; Owner: postgres; Tablespace: |
---|
| 558 | -- |
---|
| 559 | |
---|
| 560 | ALTER TABLE ONLY localidade |
---|
| 561 | ADD CONSTRAINT localidade_pkey PRIMARY KEY (organizacao_id, localidade_id); |
---|
| 562 | |
---|
| 563 | |
---|
| 564 | -- |
---|
| 565 | -- Name: organizacao_pkey; Type: CONSTRAINT; Schema: public; Owner: postgres; Tablespace: |
---|
| 566 | -- |
---|
| 567 | |
---|
| 568 | ALTER TABLE ONLY organizacao |
---|
| 569 | ADD CONSTRAINT organizacao_pkey PRIMARY KEY (organizacao_id); |
---|
| 570 | |
---|
| 571 | |
---|
| 572 | -- |
---|
| 573 | -- Name: $1; Type: FK CONSTRAINT; Schema: public; Owner: postgres |
---|
| 574 | -- |
---|
| 575 | |
---|
| 576 | ALTER TABLE ONLY funcionario_status |
---|
| 577 | ADD CONSTRAINT "$1" FOREIGN KEY (organizacao_id) REFERENCES organizacao(organizacao_id); |
---|
| 578 | |
---|
| 579 | |
---|
| 580 | -- |
---|
| 581 | -- Name: $1; Type: FK CONSTRAINT; Schema: public; Owner: postgres |
---|
| 582 | -- |
---|
| 583 | |
---|
| 584 | ALTER TABLE ONLY area_status |
---|
| 585 | ADD CONSTRAINT "$1" FOREIGN KEY (organizacao_id) REFERENCES organizacao(organizacao_id); |
---|
| 586 | |
---|
| 587 | |
---|
| 588 | -- |
---|
| 589 | -- Name: $1; Type: FK CONSTRAINT; Schema: public; Owner: postgres |
---|
| 590 | -- |
---|
| 591 | |
---|
| 592 | ALTER TABLE ONLY centro_custo |
---|
| 593 | ADD CONSTRAINT "$1" FOREIGN KEY (organizacao_id) REFERENCES organizacao(organizacao_id); |
---|
| 594 | |
---|
| 595 | |
---|
| 596 | -- |
---|
| 597 | -- Name: $1; Type: FK CONSTRAINT; Schema: public; Owner: postgres |
---|
| 598 | -- |
---|
| 599 | |
---|
| 600 | ALTER TABLE ONLY localidade |
---|
| 601 | ADD CONSTRAINT "$1" FOREIGN KEY (centro_custo_id, organizacao_id) REFERENCES centro_custo(centro_custo_id, organizacao_id); |
---|
| 602 | |
---|
| 603 | |
---|
| 604 | -- |
---|
| 605 | -- Name: $1; Type: FK CONSTRAINT; Schema: public; Owner: postgres |
---|
| 606 | -- |
---|
| 607 | |
---|
| 608 | ALTER TABLE ONLY funcionario |
---|
| 609 | ADD CONSTRAINT "$1" FOREIGN KEY (organizacao_id, centro_custo_id) REFERENCES centro_custo(organizacao_id, centro_custo_id); |
---|
| 610 | |
---|
| 611 | |
---|
| 612 | -- |
---|
| 613 | -- Name: $1; Type: FK CONSTRAINT; Schema: public; Owner: postgres |
---|
| 614 | -- |
---|
| 615 | |
---|
| 616 | ALTER TABLE ONLY area |
---|
| 617 | ADD CONSTRAINT "$1" FOREIGN KEY (superior_area_id, areasup_organizacao_id) REFERENCES area(area_id, organizacao_id); |
---|
| 618 | |
---|
| 619 | |
---|
| 620 | -- |
---|
| 621 | -- Name: $2; Type: FK CONSTRAINT; Schema: public; Owner: postgres |
---|
| 622 | -- |
---|
| 623 | |
---|
| 624 | ALTER TABLE ONLY localidade |
---|
| 625 | ADD CONSTRAINT "$2" FOREIGN KEY (organizacao_id) REFERENCES organizacao(organizacao_id); |
---|
| 626 | |
---|
| 627 | |
---|
| 628 | -- |
---|
| 629 | -- Name: $2; Type: FK CONSTRAINT; Schema: public; Owner: postgres |
---|
| 630 | -- |
---|
| 631 | |
---|
| 632 | ALTER TABLE ONLY funcionario |
---|
| 633 | ADD CONSTRAINT "$2" FOREIGN KEY (organizacao_id, localidade_id) REFERENCES localidade(organizacao_id, localidade_id); |
---|
| 634 | |
---|
| 635 | |
---|
| 636 | -- |
---|
| 637 | -- Name: $2; Type: FK CONSTRAINT; Schema: public; Owner: postgres |
---|
| 638 | -- |
---|
| 639 | |
---|
| 640 | ALTER TABLE ONLY area |
---|
| 641 | ADD CONSTRAINT "$2" FOREIGN KEY (centro_custo_id, organizacao_id) REFERENCES centro_custo(centro_custo_id, organizacao_id); |
---|
| 642 | |
---|
| 643 | |
---|
| 644 | -- |
---|
| 645 | -- Name: $3; Type: FK CONSTRAINT; Schema: public; Owner: postgres |
---|
| 646 | -- |
---|
| 647 | |
---|
| 648 | ALTER TABLE ONLY funcionario |
---|
| 649 | ADD CONSTRAINT "$3" FOREIGN KEY (organizacao_id, area_id) REFERENCES area(organizacao_id, area_id); |
---|
| 650 | |
---|
| 651 | |
---|
| 652 | -- |
---|
| 653 | -- Name: $3; Type: FK CONSTRAINT; Schema: public; Owner: postgres |
---|
| 654 | -- |
---|
| 655 | |
---|
| 656 | ALTER TABLE ONLY area |
---|
| 657 | ADD CONSTRAINT "$3" FOREIGN KEY (titular_funcionario_id) REFERENCES funcionario(funcionario_id); |
---|
| 658 | |
---|
| 659 | |
---|
| 660 | -- |
---|
| 661 | -- Name: $4; Type: FK CONSTRAINT; Schema: public; Owner: postgres |
---|
| 662 | -- |
---|
| 663 | |
---|
| 664 | ALTER TABLE ONLY funcionario |
---|
| 665 | ADD CONSTRAINT "$4" FOREIGN KEY (funcionario_status_id) REFERENCES funcionario_status(funcionario_status_id); |
---|
| 666 | |
---|
| 667 | |
---|
| 668 | -- |
---|
| 669 | -- Name: $4; Type: FK CONSTRAINT; Schema: public; Owner: postgres |
---|
| 670 | -- |
---|
| 671 | |
---|
| 672 | ALTER TABLE ONLY area |
---|
| 673 | ADD CONSTRAINT "$4" FOREIGN KEY (substituto_funcionario_id) REFERENCES funcionario(funcionario_id); |
---|
| 674 | |
---|
| 675 | |
---|
| 676 | -- |
---|
| 677 | -- Name: $5; Type: FK CONSTRAINT; Schema: public; Owner: postgres |
---|
| 678 | -- |
---|
| 679 | |
---|
| 680 | ALTER TABLE ONLY area |
---|
| 681 | ADD CONSTRAINT "$5" FOREIGN KEY (organizacao_id) REFERENCES organizacao(organizacao_id); |
---|
| 682 | |
---|
| 683 | |
---|
| 684 | -- |
---|
| 685 | -- Name: $6; Type: FK CONSTRAINT; Schema: public; Owner: postgres |
---|
| 686 | -- |
---|
| 687 | |
---|
| 688 | ALTER TABLE ONLY area |
---|
| 689 | ADD CONSTRAINT "$6" FOREIGN KEY (area_status_id, organizacao_id) REFERENCES area_status(area_status_id, organizacao_id); |
---|
| 690 | |
---|
| 691 | |
---|
| 692 | -- |
---|
| 693 | -- Name: $7; Type: FK CONSTRAINT; Schema: public; Owner: postgres |
---|
| 694 | -- |
---|
| 695 | |
---|
| 696 | ALTER TABLE ONLY area |
---|
| 697 | ADD CONSTRAINT "$7" FOREIGN KEY (auxiliar_funcionario_id) REFERENCES funcionario(funcionario_id); |
---|
| 698 | |
---|
| 699 | |
---|
| 700 | -- |
---|
| 701 | -- Name: cds; Type: ACL; Schema: -; Owner: admin_cds |
---|
| 702 | -- |
---|
| 703 | |
---|
| 704 | REVOKE ALL ON SCHEMA cds FROM PUBLIC; |
---|
| 705 | REVOKE ALL ON SCHEMA cds FROM admin_cds; |
---|
| 706 | GRANT ALL ON SCHEMA cds TO admin_cds; |
---|
| 707 | GRANT ALL ON SCHEMA cds TO postgres; |
---|
| 708 | |
---|
| 709 | |
---|
| 710 | -- |
---|
| 711 | -- Name: public; Type: ACL; Schema: -; Owner: postgres |
---|
| 712 | -- |
---|
| 713 | |
---|
| 714 | REVOKE ALL ON SCHEMA public FROM PUBLIC; |
---|
| 715 | REVOKE ALL ON SCHEMA public FROM postgres; |
---|
| 716 | GRANT ALL ON SCHEMA public TO postgres; |
---|
| 717 | GRANT ALL ON SCHEMA public TO PUBLIC; |
---|
| 718 | |
---|
| 719 | |
---|
| 720 | SET search_path = cds, pg_catalog; |
---|
| 721 | |
---|
| 722 | -- |
---|
| 723 | -- Name: cdcollection; Type: ACL; Schema: cds; Owner: admin_cds |
---|
| 724 | -- |
---|
| 725 | |
---|
| 726 | REVOKE ALL ON TABLE cdcollection FROM PUBLIC; |
---|
| 727 | REVOKE ALL ON TABLE cdcollection FROM admin_cds; |
---|
| 728 | GRANT ALL ON TABLE cdcollection TO admin_cds; |
---|
| 729 | GRANT ALL ON TABLE cdcollection TO postgres WITH GRANT OPTION; |
---|
| 730 | |
---|
| 731 | |
---|
| 732 | SET search_path = public, pg_catalog; |
---|
| 733 | |
---|
| 734 | -- |
---|
| 735 | -- Name: area; Type: ACL; Schema: public; Owner: postgres |
---|
| 736 | -- |
---|
| 737 | |
---|
| 738 | REVOKE ALL ON TABLE area FROM PUBLIC; |
---|
| 739 | REVOKE ALL ON TABLE area FROM postgres; |
---|
| 740 | GRANT ALL ON TABLE area TO postgres; |
---|
| 741 | GRANT ALL ON TABLE area TO admin_workflow; |
---|
| 742 | GRANT SELECT ON TABLE area TO PUBLIC; |
---|
| 743 | |
---|
| 744 | |
---|
| 745 | -- |
---|
| 746 | -- Name: area_area_id_seq; Type: ACL; Schema: public; Owner: postgres |
---|
| 747 | -- |
---|
| 748 | |
---|
| 749 | REVOKE ALL ON SEQUENCE area_area_id_seq FROM PUBLIC; |
---|
| 750 | REVOKE ALL ON SEQUENCE area_area_id_seq FROM postgres; |
---|
| 751 | GRANT ALL ON SEQUENCE area_area_id_seq TO postgres; |
---|
| 752 | GRANT ALL ON SEQUENCE area_area_id_seq TO admin_workflow; |
---|
| 753 | GRANT SELECT ON SEQUENCE area_area_id_seq TO PUBLIC; |
---|
| 754 | |
---|
| 755 | |
---|
| 756 | -- |
---|
| 757 | -- Name: area_status; Type: ACL; Schema: public; Owner: postgres |
---|
| 758 | -- |
---|
| 759 | |
---|
| 760 | REVOKE ALL ON TABLE area_status FROM PUBLIC; |
---|
| 761 | REVOKE ALL ON TABLE area_status FROM postgres; |
---|
| 762 | GRANT ALL ON TABLE area_status TO postgres; |
---|
| 763 | GRANT ALL ON TABLE area_status TO admin_workflow; |
---|
| 764 | GRANT SELECT ON TABLE area_status TO PUBLIC; |
---|
| 765 | |
---|
| 766 | |
---|
| 767 | -- |
---|
| 768 | -- Name: area_status_area_status_id_seq; Type: ACL; Schema: public; Owner: postgres |
---|
| 769 | -- |
---|
| 770 | |
---|
| 771 | REVOKE ALL ON SEQUENCE area_status_area_status_id_seq FROM PUBLIC; |
---|
| 772 | REVOKE ALL ON SEQUENCE area_status_area_status_id_seq FROM postgres; |
---|
| 773 | GRANT ALL ON SEQUENCE area_status_area_status_id_seq TO postgres; |
---|
| 774 | GRANT ALL ON SEQUENCE area_status_area_status_id_seq TO admin_workflow; |
---|
| 775 | GRANT SELECT ON SEQUENCE area_status_area_status_id_seq TO PUBLIC; |
---|
| 776 | |
---|
| 777 | |
---|
| 778 | -- |
---|
| 779 | -- Name: cargo; Type: ACL; Schema: public; Owner: postgres |
---|
| 780 | -- |
---|
| 781 | |
---|
| 782 | REVOKE ALL ON TABLE cargo FROM PUBLIC; |
---|
| 783 | REVOKE ALL ON TABLE cargo FROM postgres; |
---|
| 784 | GRANT ALL ON TABLE cargo TO postgres; |
---|
| 785 | GRANT ALL ON TABLE cargo TO admin_workflow; |
---|
| 786 | GRANT SELECT ON TABLE cargo TO PUBLIC; |
---|
| 787 | |
---|
| 788 | |
---|
| 789 | -- |
---|
| 790 | -- Name: cargo_cargo_id_seq; Type: ACL; Schema: public; Owner: postgres |
---|
| 791 | -- |
---|
| 792 | |
---|
| 793 | REVOKE ALL ON SEQUENCE cargo_cargo_id_seq FROM PUBLIC; |
---|
| 794 | REVOKE ALL ON SEQUENCE cargo_cargo_id_seq FROM postgres; |
---|
| 795 | GRANT ALL ON SEQUENCE cargo_cargo_id_seq TO postgres; |
---|
| 796 | GRANT ALL ON SEQUENCE cargo_cargo_id_seq TO admin_workflow; |
---|
| 797 | GRANT SELECT ON SEQUENCE cargo_cargo_id_seq TO PUBLIC; |
---|
| 798 | |
---|
| 799 | |
---|
| 800 | -- |
---|
| 801 | -- Name: centro_custo; Type: ACL; Schema: public; Owner: postgres |
---|
| 802 | -- |
---|
| 803 | |
---|
| 804 | REVOKE ALL ON TABLE centro_custo FROM PUBLIC; |
---|
| 805 | REVOKE ALL ON TABLE centro_custo FROM postgres; |
---|
| 806 | GRANT ALL ON TABLE centro_custo TO postgres; |
---|
| 807 | GRANT ALL ON TABLE centro_custo TO admin_workflow; |
---|
| 808 | GRANT SELECT ON TABLE centro_custo TO PUBLIC; |
---|
| 809 | |
---|
| 810 | |
---|
| 811 | -- |
---|
| 812 | -- Name: centro_custo_centro_custo_id_seq; Type: ACL; Schema: public; Owner: postgres |
---|
| 813 | -- |
---|
| 814 | |
---|
| 815 | REVOKE ALL ON SEQUENCE centro_custo_centro_custo_id_seq FROM PUBLIC; |
---|
| 816 | REVOKE ALL ON SEQUENCE centro_custo_centro_custo_id_seq FROM postgres; |
---|
| 817 | GRANT ALL ON SEQUENCE centro_custo_centro_custo_id_seq TO postgres; |
---|
| 818 | GRANT ALL ON SEQUENCE centro_custo_centro_custo_id_seq TO admin_workflow; |
---|
| 819 | GRANT SELECT ON SEQUENCE centro_custo_centro_custo_id_seq TO PUBLIC; |
---|
| 820 | |
---|
| 821 | |
---|
| 822 | -- |
---|
| 823 | -- Name: funcionario; Type: ACL; Schema: public; Owner: postgres |
---|
| 824 | -- |
---|
| 825 | |
---|
| 826 | REVOKE ALL ON TABLE funcionario FROM PUBLIC; |
---|
| 827 | REVOKE ALL ON TABLE funcionario FROM postgres; |
---|
| 828 | GRANT ALL ON TABLE funcionario TO postgres; |
---|
| 829 | GRANT ALL ON TABLE funcionario TO admin_workflow; |
---|
| 830 | GRANT SELECT ON TABLE funcionario TO PUBLIC; |
---|
| 831 | |
---|
| 832 | |
---|
| 833 | -- |
---|
| 834 | -- Name: funcionario_categoria; Type: ACL; Schema: public; Owner: postgres |
---|
| 835 | -- |
---|
| 836 | |
---|
| 837 | REVOKE ALL ON TABLE funcionario_categoria FROM PUBLIC; |
---|
| 838 | REVOKE ALL ON TABLE funcionario_categoria FROM postgres; |
---|
| 839 | GRANT ALL ON TABLE funcionario_categoria TO postgres; |
---|
| 840 | GRANT ALL ON TABLE funcionario_categoria TO admin_workflow; |
---|
| 841 | GRANT SELECT ON TABLE funcionario_categoria TO PUBLIC; |
---|
| 842 | |
---|
| 843 | |
---|
| 844 | -- |
---|
| 845 | -- Name: funcionario_categoria_funcionario_categoria_id_seq; Type: ACL; Schema: public; Owner: postgres |
---|
| 846 | -- |
---|
| 847 | |
---|
| 848 | REVOKE ALL ON SEQUENCE funcionario_categoria_funcionario_categoria_id_seq FROM PUBLIC; |
---|
| 849 | REVOKE ALL ON SEQUENCE funcionario_categoria_funcionario_categoria_id_seq FROM postgres; |
---|
| 850 | GRANT ALL ON SEQUENCE funcionario_categoria_funcionario_categoria_id_seq TO postgres; |
---|
| 851 | GRANT ALL ON SEQUENCE funcionario_categoria_funcionario_categoria_id_seq TO admin_workflow; |
---|
| 852 | GRANT SELECT ON SEQUENCE funcionario_categoria_funcionario_categoria_id_seq TO PUBLIC; |
---|
| 853 | |
---|
| 854 | |
---|
| 855 | -- |
---|
| 856 | -- Name: funcionario_status; Type: ACL; Schema: public; Owner: postgres |
---|
| 857 | -- |
---|
| 858 | |
---|
| 859 | REVOKE ALL ON TABLE funcionario_status FROM PUBLIC; |
---|
| 860 | REVOKE ALL ON TABLE funcionario_status FROM postgres; |
---|
| 861 | GRANT ALL ON TABLE funcionario_status TO postgres; |
---|
| 862 | GRANT ALL ON TABLE funcionario_status TO admin_workflow; |
---|
| 863 | GRANT SELECT ON TABLE funcionario_status TO PUBLIC; |
---|
| 864 | |
---|
| 865 | |
---|
| 866 | -- |
---|
| 867 | -- Name: funcionario_status_funcionario_status_id_seq; Type: ACL; Schema: public; Owner: postgres |
---|
| 868 | -- |
---|
| 869 | |
---|
| 870 | REVOKE ALL ON SEQUENCE funcionario_status_funcionario_status_id_seq FROM PUBLIC; |
---|
| 871 | REVOKE ALL ON SEQUENCE funcionario_status_funcionario_status_id_seq FROM postgres; |
---|
| 872 | GRANT ALL ON SEQUENCE funcionario_status_funcionario_status_id_seq TO postgres; |
---|
| 873 | GRANT ALL ON SEQUENCE funcionario_status_funcionario_status_id_seq TO admin_workflow; |
---|
| 874 | GRANT SELECT ON SEQUENCE funcionario_status_funcionario_status_id_seq TO PUBLIC; |
---|
| 875 | |
---|
| 876 | |
---|
| 877 | -- |
---|
| 878 | -- Name: localidade; Type: ACL; Schema: public; Owner: postgres |
---|
| 879 | -- |
---|
| 880 | |
---|
| 881 | REVOKE ALL ON TABLE localidade FROM PUBLIC; |
---|
| 882 | REVOKE ALL ON TABLE localidade FROM postgres; |
---|
| 883 | GRANT ALL ON TABLE localidade TO postgres; |
---|
| 884 | GRANT ALL ON TABLE localidade TO admin_workflow; |
---|
| 885 | GRANT SELECT ON TABLE localidade TO PUBLIC; |
---|
| 886 | |
---|
| 887 | |
---|
| 888 | -- |
---|
| 889 | -- Name: localidade_localidade_id_seq; Type: ACL; Schema: public; Owner: postgres |
---|
| 890 | -- |
---|
| 891 | |
---|
| 892 | REVOKE ALL ON SEQUENCE localidade_localidade_id_seq FROM PUBLIC; |
---|
| 893 | REVOKE ALL ON SEQUENCE localidade_localidade_id_seq FROM postgres; |
---|
| 894 | GRANT ALL ON SEQUENCE localidade_localidade_id_seq TO postgres; |
---|
| 895 | GRANT ALL ON SEQUENCE localidade_localidade_id_seq TO admin_workflow; |
---|
| 896 | GRANT SELECT ON SEQUENCE localidade_localidade_id_seq TO PUBLIC; |
---|
| 897 | |
---|
| 898 | |
---|
| 899 | -- |
---|
| 900 | -- Name: organizacao; Type: ACL; Schema: public; Owner: postgres |
---|
| 901 | -- |
---|
| 902 | |
---|
| 903 | REVOKE ALL ON TABLE organizacao FROM PUBLIC; |
---|
| 904 | REVOKE ALL ON TABLE organizacao FROM postgres; |
---|
| 905 | GRANT ALL ON TABLE organizacao TO postgres; |
---|
| 906 | GRANT ALL ON TABLE organizacao TO admin_workflow; |
---|
| 907 | GRANT SELECT ON TABLE organizacao TO PUBLIC; |
---|
| 908 | |
---|
| 909 | |
---|
| 910 | -- |
---|
| 911 | -- Name: organizacao_organizacao_id_seq; Type: ACL; Schema: public; Owner: postgres |
---|
| 912 | -- |
---|
| 913 | |
---|
| 914 | REVOKE ALL ON SEQUENCE organizacao_organizacao_id_seq FROM PUBLIC; |
---|
| 915 | REVOKE ALL ON SEQUENCE organizacao_organizacao_id_seq FROM postgres; |
---|
| 916 | GRANT ALL ON SEQUENCE organizacao_organizacao_id_seq TO postgres; |
---|
| 917 | GRANT ALL ON SEQUENCE organizacao_organizacao_id_seq TO admin_workflow; |
---|
| 918 | GRANT SELECT ON SEQUENCE organizacao_organizacao_id_seq TO PUBLIC; |
---|
| 919 | |
---|
| 920 | |
---|
| 921 | -- |
---|
| 922 | -- PostgreSQL database dump complete |
---|
| 923 | -- |
---|
| 924 | |
---|