Hi
I have got a many-to-many relation between tables 'projects' and 'people' stored in an 'assignments' table.
I have defined this relation in table/people/relationships.ini as follows:
[Assignments]
__sql__="select * from projects, assignments where projects.project_id = assignments.project_id and assignments.person_id = '$person_id'"
the assignment table is defined as follows:
CREATE TABLE assignments (
`person_id` int(10) signed NOT NULL,
`project_id` int(10) signed NOT NULL,
`start_date` date,
`end_date` date,
PRIMARY KEY (`person_id`,`project_id`)
)
ENGINE=InnoDB DEFAULT CHARSET=utf8;
The relation tab is displayed correctly and when I use an "add existing assignments record" button, I have the possibility of selecting a project to assign and I can choose dates for the assignment. After saving, the assignment (person_id and project_id) is saved but fields start_date and end_date are set to NULL.
NULL values are set if I write the dates manually e.g. '2006-11-11' or when I use a calendar add-on.
The problem is no showing up id I change the type of 'start_date' and 'end_date' fields to ?varchar?:
Can anyone help me to solve the problem?
regards
Borek