【The same record’s status was updated—how do you avoid counting it twice?】

A status history table may record both the start and the success of an operation. If you simply count the rows, one operation may be counted twice. To count the current number of operations, get the latest status for each business ID; to see how many status changes occurred in the system, count each event row. Both methods have their uses—first decide what question you want to answer.

Follow me to keep learning how to understand a table from a single record.