Added indexes on the foreign keys.