I'm doing a small website for me and a couple of friends where we can bet on UFC events (http://www.ufc.com)
Trying to keep it very simple and not go overboard as usual.
So. You first add an event, selecting date. Then you add fights to that event selecting players already put in the database. Structure looking like this so far:
Code: Select all
event
id | name | event_date | created_by | create_date
fighter
id | name | url | wins | losses | noc | created_by | create_date
fight
event_id | fighter1_id | fighter2_id | result | time |
w = win
l = loss
tko = technical knock out
noc = no contest
s = submission
So should result be 0 for win, 1 for loss, 2 to for tko and 3 for submission and how would it determine which fighter won when you retrieve the data?
Please help me Obi Wan.