![]() |
Database Structure
I'm trying to plan a database structure for a custom mod. Its going to be a personal points, and this is how it will work.
Every saturday I will have a list of points that I will manually add myself. The week starts on saturday and ends on friday. I want to keep a record of points earned everyweek. For instance. User1 has 150 points for week(1) User1 has 125 points for week(2) ------------------------------------------- Total Points: 275 What would be the best approach to handle the weeks orginaized? |
You can make the week table auto increment.
Table Scheme: Name: points_record userid points_this_week week_number I would point total points in a separate table...perhaps the user table. Could be wrong though! |
Well it really depends on how long history you want to keep. If not too much, then maybe just a serialized array in the user table would be best.
|
Don't serialize stuff into the database unless absolutely necessary. It defeats the purpose of using the database in the first place.
|
Thanks guys, I think I figured out the best way. I'll let you know how it goes. :)
|
All times are GMT. The time now is 12:27 AM. |
Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|