Hi mikosiko.
After some frustration I started thinking more about my table structures and that they could be a poor design.
Do you mean something like this? Do I need to change my tables to InnoDB then? I just enabled it on my localhost, but not sure about my server.
Employees
+------+---------+
| id | name |
+------+---------+
| 001 | Joe |
| 002 | Sam |
| 003 | Mary |
| 004 | Bill |
| 005 | Jane |
+------+---------+
Schedule
+-------+------------+
| id | date |
+-------+------------+
| 1 | 2011-07-28 |
| 2 | 2011-07-29 |
+-------+------------+
Employee_Schedule
+-------+---------------+----------+
| id | shift_type | employee |
+-------+---------------+----------+
| 1 | morn | 003 |
| 2 | day | 001 |
| 3 | eve | 005 |
+-------+---------------+----------+
I'm not sure how the relationship between the dates and the employee_schedule would work. How will I know which date is related to the employee_schedule?
Also, wouldn't I need to use a double insert then like this?
INSERT INTO schedule (id, date)
VALUES('3', '2011-07-30');
INSERT INTO employee_schedule (id, shift_type, employee)
VALUES('4', 'day', '005');