17 Tracking Changes to Voter Data with Triggers

In this chapter, you’ll build a voting database that stores data for an election. You’ll improve the quality of your data by designing the database with constraints, including primary and foreign keys, and using triggers to prevent bad data from being entered. You’ll also use triggers to track changes to your database so that if data quality issues arise, you have a record of who made the changes and when.

You’ll allow poll workers to change data when appropriate, so it’s important to build a system that prevents errors from being made. The techniques in this chapter can be applied to a wide ...

Get MySQL Crash Course now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.