RobDog888
01-29-2008, 05:49 AM
What is the benefits of having some field that is a sum updated via a count table? For example the "views" table when instant updates are not on will add a single record and thread id for everytime the thread is viewed. Then the cron job runs and updated the sum of those grouped records to each associated thread's views field in the thread table.
Is this really worth the effort as everytime you are viewing a thread there is an INSERT happening to the views table so why not just add 1 to the thread tables views field with an UPDATE as its still a single db call. Plus with the cron job it will blast all the records on an hourly basis which may add a surge of resource useage.
So which would be better and why?
Sorry for the long post but couldnt make it shorter :D
Is this really worth the effort as everytime you are viewing a thread there is an INSERT happening to the views table so why not just add 1 to the thread tables views field with an UPDATE as its still a single db call. Plus with the cron job it will blast all the records on an hourly basis which may add a surge of resource useage.
So which would be better and why?
Sorry for the long post but couldnt make it shorter :D