Last active
October 8, 2015 01:23
-
-
Save geisonsn/087e67c0feeef73ddb5c to your computer and use it in GitHub Desktop.
Aula do dia 05/10/2015 - Exercício sobre trigger
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
create or replace trigger full_name_trigger | |
BEFORE insert or update on employees | |
for each row | |
begin | |
:new.full_name := :new.first_name || ' ' || :new.last_name; | |
END; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
create or replace procedure sp_plsql is | |
p_dept_id DEPARTMENTS.DEPARTMENT_ID%type; | |
begin | |
end; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Criar procedure chamada SP_PLSQL que recebe um parâmetro chamado p_dept_id departments.department_id%type. Criar um cursor que vai fazer a listagem dos empregados do departamento.