Script libera perfil para acessar botão de declarar omisso

parent 6edfa6ea
DO $$
DECLARE
v_list_cpfs text[] := ARRAY['59883855168','03116499128','11283047675','85513776120','90541758268','67423493600','99272741149','01423427181','03566429171','50420836187', '86385305104','01810687101'];
v_cpf text;
PFLCOD CONSTANT INTEGER := 3128;
BEGIN
FOREACH v_cpf in ARRAY v_list_cpfs LOOP
BEGIN
RAISE NOTICE 'Seguintes CPFs % CONSTANTE %', v_cpf, PFLCOD;
INSERT INTO seguranca.perfilusuario (usucpf, pflcod) VALUES(v_cpf, PFLCOD);
RAISE NOTICE 'Inserido com sucesso o CPF = % no perfil do botao declaracao omissao', v_cpf;
EXCEPTION WHEN others THEN RAISE NOTICE 'Registro já existe ou não pode ser inserido';
END;
END LOOP;
END; $$;
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment