Updated with a 'createAllTables' scratch function.