Index: lams_tool_chat/db/sql/updatescripts/updateTo20080229.sql =================================================================== diff -u -r98f10c35c8f290b7f3bcea1908f22cd77e7e8943 -r36aa2a4d14c54dc5a486aa4b45d3ee94be976f77 --- lams_tool_chat/db/sql/updatescripts/updateTo20080229.sql (.../updateTo20080229.sql) (revision 98f10c35c8f290b7f3bcea1908f22cd77e7e8943) +++ lams_tool_chat/db/sql/updatescripts/updateTo20080229.sql (.../updateTo20080229.sql) (revision 36aa2a4d14c54dc5a486aa4b45d3ee94be976f77) @@ -4,5 +4,11 @@ ALTER TABLE tl_lachat11_message ENGINE=InnoDB; ALTER TABLE tl_lachat11_session ENGINE=InnoDB; ALTER TABLE tl_lachat11_user ENGINE=InnoDB; +alter table tl_lachat11_attachment add foreign key (chat_uid) references tl_lachat11_chat (uid); +alter table tl_lachat11_message add foreign key (to_user_uid) references tl_lachat11_user (uid); +alter table tl_lachat11_message add foreign key (chat_session_uid) references tl_lachat11_session (uid); +alter table tl_lachat11_message add foreign key (from_user_uid) references tl_lachat11_user (uid); +alter table tl_lachat11_session add foreign key (chat_uid) references tl_lachat11_chat (uid); +alter table tl_lachat11_user add foreign key (chat_session_uid) references tl_lachat11_session (uid); UPDATE lams_tool SET modified_date_time = NOW() WHERE tool_signature = "lachat11"; UPDATE lams_tool SET tool_version = "20080229" WHERE tool_signature = "lachat11"; \ No newline at end of file