Use postgreSQL code that creates a trigger on the detailed table of the report that will continually
Question:
Use postgreSQL code that creates a trigger on the detailed table of the report that will continually update the summary table as data is added to the detailed table.
This is the code I have so far, but I am having trouble testing it to see if it works properly. My summary table and detailed table both use the same fields with the differences being my summary tables SUMS all the rows for employee_sales together while the detailed table has each individual row along with an additional column for a timestamp of the transaction.
Please explain how I test this code to see if it works and let me know if you see any errors or issues with the code. Primarily I need an insert statement that works and then a way to remove the row inserted afterwards so it doesn't affect my data.
Accounting Information Systems
ISBN: 9780132871938
11th Edition
Authors: George H. Bodnar, William S. Hopwood