Connected the discussions to the database