SELECT * FROM video_category INNER JOIN category ON category.id = video_category.category_id INNER JOIN videos ON videos.id = video_category.video_id WHERE video_category.category_id = " .((int)$_GET['id'])
Как правильно дополнить это
ORDER BY video_category.video_id DESC
Если я его добавляю, появляется ошибка Warning: mysqli_fetch_array() expects parameter 1 to be mysqli_result, boolean given
$res = mysqli_query($connection, "SELECT * FROM video_category INNER JOIN category ON category.id = video_category.category_id INNER JOIN videos ON videos.id = video_category.video_id WHERE video_category.category_id = " .((int)$_GET['id'])."ORDER BY video_category.video_id DESC");
$videos = array();
while($row = mysqli_fetch_array($res)){
$videos[] = $row;
}