Updating the summary table based on triggers and stored procedures
问题 I have a typical LAMP based site + Zend Framework where I have a base table and a summary table. Summary table is used to display data in reports. Base table - ID | Status 1 | 1 2 | 1 3 | 2 4 | 2 5 | 1 6 | 1 Summary table - Status | Count 1 | 4 2 | 2 The base table will be changed(insert,update,delete) at an average of 20 times per day. Currently, I am using triggers to call a stored procedure which will update the summary table based on the base table. This is the stored procedure. CREATE