+=+=+=+=+=+=+=+=+= Drew Hengehold +=+=+=+=+=+=+=+=+= Trigger created. No errors. +=+=+= Testing log_salary +=+=+= Commit complete. +=+=+= Pretest Version of empl and salary_history +=+=+= EMPL EMPL_LAST_NAME JOB_TITLE MGR HIREDATE SALARY COMMISSION DEP ---- --------------- ---------- ---- --------- ---------- ---------- --- 7839 King President 17-NOV-11 5000 500 7566 Jones Manager 7839 02-APR-12 2975 200 7698 Blake Manager 7839 01-MAY-13 2850 300 7782 Raimi Manager 7839 09-JUN-12 2450 100 7902 Ford Analyst 7566 03-DEC-12 3000 200 7369 Smith Clerk 7902 17-DEC-12 800 200 7499 Michaels Sales 7698 20-FEB-18 1600 300 300 7521 Ward Sales 7698 22-FEB-19 1250 500 300 7654 Martin Sales 7698 28-SEP-18 1250 1400 300 7788 Scott Analyst 7566 09-NOV-18 3000 200 7844 Turner Sales 7698 08-SEP-19 1500 0 300 EMPL EMPL_LAST_NAME JOB_TITLE MGR HIREDATE SALARY COMMISSION DEP ---- --------------- ---------- ---- --------- ---------- ---------- --- 7876 Adams Clerk 7788 23-SEP-18 1100 400 7900 James Clerk 7698 03-DEC-17 950 300 7934 Miller Clerk 7782 23-JAN-16 1300 100 14 rows selected. EMPL PREV_SALARY NEXT_SALARY CHANGE_DA ---- ----------- ----------- --------- 7839 5000 17-NOV-11 7566 2975 02-APR-12 7698 2850 01-MAY-13 7782 2450 09-JUN-12 7902 3000 03-DEC-12 7369 800 17-DEC-12 7499 1600 20-FEB-18 7521 1250 22-FEB-19 7654 1250 28-SEP-18 7788 3000 09-NOV-18 7844 1500 08-SEP-19 EMPL PREV_SALARY NEXT_SALARY CHANGE_DA ---- ----------- ----------- --------- 7876 1100 23-SEP-18 7900 950 03-DEC-17 7934 1300 23-JAN-16 14 rows selected. +=+=+= Test 1, testing insertion +=+=+= (inserting Abrams into empl) 1 row created. -+-+-+-+-+-+-+-+- You should now see 15 rows in salary_history -+-+-+-+-+-+-+-+- EMPL PREV_SALARY NEXT_SALARY CHANGE_DA ---- ----------- ----------- --------- 7839 5000 17-NOV-11 7566 2975 02-APR-12 7698 2850 01-MAY-13 7782 2450 09-JUN-12 7902 3000 03-DEC-12 7369 800 17-DEC-12 7499 1600 20-FEB-18 7521 1250 22-FEB-19 7654 1250 28-SEP-18 7788 3000 09-NOV-18 7844 1500 08-SEP-19 EMPL PREV_SALARY NEXT_SALARY CHANGE_DA ---- ----------- ----------- --------- 7876 1100 23-SEP-18 7900 950 03-DEC-17 7934 1300 23-JAN-16 9329 1000 17-NOV-21 15 rows selected. +=+=+= Test 2, testing updating +=+=+= (updating Blake salary from 2850 to 3000) 1 row updated. +=+=+= Test 3, testing updating +=+=+= (updating Ford job_title from Analyst to Clerk) 1 row updated. -+-+-+-+-+-+-+-+- You should now see Ford with job title clerk and Blake with salary 3000 in table empl -+-+-+-+-+-+-+-+- EMPL EMPL_LAST_NAME JOB_TITLE MGR HIREDATE SALARY COMMISSION DEP ---- --------------- ---------- ---- --------- ---------- ---------- --- 7839 King President 17-NOV-11 5000 500 7566 Jones Manager 7839 02-APR-12 2975 200 7698 Blake Manager 7839 01-MAY-13 3000 300 7782 Raimi Manager 7839 09-JUN-12 2450 100 7902 Ford Clerk 7566 03-DEC-12 3000 200 7369 Smith Clerk 7902 17-DEC-12 800 200 7499 Michaels Sales 7698 20-FEB-18 1600 300 300 7521 Ward Sales 7698 22-FEB-19 1250 500 300 7654 Martin Sales 7698 28-SEP-18 1250 1400 300 7788 Scott Analyst 7566 09-NOV-18 3000 200 7844 Turner Sales 7698 08-SEP-19 1500 0 300 EMPL EMPL_LAST_NAME JOB_TITLE MGR HIREDATE SALARY COMMISSION DEP ---- --------------- ---------- ---- --------- ---------- ---------- --- 7876 Adams Clerk 7788 23-SEP-18 1100 400 7900 James Clerk 7698 03-DEC-17 950 300 7934 Miller Clerk 7782 23-JAN-16 1300 100 9329 Abrams Manager 7839 17-NOV-21 1000 100 15 rows selected. -+-+-+-+-+-+-+-+- You should now see 16 rows in salary_history with the last entry being from Blake whos salary went from 2850 to 3000 -+-+-+-+-+-+-+-+- EMPL PREV_SALARY NEXT_SALARY CHANGE_DA ---- ----------- ----------- --------- 7839 5000 17-NOV-11 7566 2975 02-APR-12 7698 2850 01-MAY-13 7782 2450 09-JUN-12 7902 3000 03-DEC-12 7369 800 17-DEC-12 7499 1600 20-FEB-18 7521 1250 22-FEB-19 7654 1250 28-SEP-18 7788 3000 09-NOV-18 7844 1500 08-SEP-19 EMPL PREV_SALARY NEXT_SALARY CHANGE_DA ---- ----------- ----------- --------- 7876 1100 23-SEP-18 7900 950 03-DEC-17 7934 1300 23-JAN-16 9329 1000 17-NOV-21 7698 2850 3000 10-MAR-25 16 rows selected. Rollback complete.