Derived account balance vs stored account balance for a simple bank account?

Preface There is an objective truth: Audit requirements. Additionally, when dealing with public funds, there is Legislature that must be complied with. You don’t have to implement the full accounting requirement, you can implement just the parts that you need. Conversely, it would be ill-advised to implement something other than the standard accounting requirement (the … Read more

Create a temporary table in a SELECT statement without a separate CREATE TABLE

CREATE TEMPORARY TABLE IF NOT EXISTS table2 AS (SELECT * FROM table1) From the manual found at http://dev.mysql.com/doc/refman/5.7/en/create-table.html You can use the TEMPORARY keyword when creating a table. A TEMPORARY table is visible only to the current session, and is dropped automatically when the session is closed. This means that two different sessions can use … Read more