I have five tables as listed below.
Question: is it possible to join all five tables and output the result as show below?
<table>
<tr>
<th>Subject</th>
<th>Last update (date from table. nr.3)</th>
<th>Last update (date from table. nr.4)</th>
<th>Last update (date from table. nr.5)</th>
</tr>
<tr>
<td>Mathematics</td>
<td>2014-06-01</td>
<td>2014-07-05</td>
<td>2014-03-15</td>
</tr>
<tr>
<td>English</td>
<td>2014-01-01</td>
<td>2014-02-11</td>
<td>2014-04-21</td>
</tr>
<tr>
<td>German</td>
<td>2014-01-02</td>
<td>2014-05-30</td>
<td>2014-07-03</td>
<tr>
</table>
Table (containing subject id and subject name)
CREATE TABLE IF NOT EXISTS `subject` (
`subject_id` int(3) NOT NULL AUTO_INCREMENT,
`subject_name` varchar(50) COLLATE utf8_swedish_ci NOT NULL,
PRIMARY KEY (`amne_id`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_swedish_ci AUTO_INCREMENT=100 ;
Table (containing subjects that not will be read current semester)
CREATE TABLE IF NOT EXISTS `reading_subject` (
`read_id` int(5) unsigned NOT NULL AUTO_INCREMENT,
`class` varchar(3) COLLATE utf8_swedish_ci NOT NULL,
`subject_id` int(3) NOT NULL,
`semester` varchar(2) COLLATE utf8_swedish_ci DEFAULT NULL,
PRIMARY KEY (`read_id`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_swedish_ci AUTO_INCREMENT=25 ;
Table (nr. 3, containing information regarding each assessment)
CREATE TABLE IF NOT EXISTS `kunskapskrav_klick` (
`kun_id` int(11) unsigned NOT NULL AUTO_INCREMENT,
`subject_id` int(3) NOT NULL,
`student_id` int(3) NOT NULL,
`teacher_id` int(3) NOT NULL,
`semester` varchar(2) COLLATE utf8_swedish_ci NOT NULL,
`date_a` date NOT NULL,
PRIMARY KEY (`kun_id`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_swedish_ci AUTO_INCREMENT=45699 ;
Table (nr.4, containing assessment from teacher)
CREATE TABLE IF NOT EXISTS `assess_teacher` (
`kuns_id_teacher` int(10) NOT NULL AUTO_INCREMENT,
`subject_id` int(3) NOT NULL,
`student_id` int(10) NOT NULL,
`teacher_id` int(3) NOT NULL,
`semester` varchar(25) COLLATE utf8_swedish_ci NOT NULL,
`date` varchar(25) CHARACTER SET latin1 NOT NULL DEFAULT '',
PRIMARY KEY (`kuns_id_teacher`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_swedish_ci AUTO_INCREMENT=7560 ;
Table (nr.5, containing text from student)
CREATE TABLE IF NOT EXISTS `assess_student` (
`kuns_id_student` int(10) NOT NULL AUTO_INCREMENT,
`subject_id` int(3) NOT NULL,
`student_id` int(3) NOT NULL,
`teacher_id` int(3) NOT NULL,
`date` date NOT NULL,
PRIMARY KEY (`kuns_id_student`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_swedish_ci AUTO_INCREMENT=6142 ;