Untitled

mail@pastecode.io avatar
unknown
plain_text
3 years ago
395 B
0
Indexable
Never
SELECT
  videos.id
FROM videos 
WHERE 
videos.id IN(SELECT links.video_id
FROM links
WHERE links.playlist_id IN(
  SELECT mp.playlist_id
  FROM material_playlists mp
  WHERE mp.material_id IN(
    SELECT materials.id
    FROM materials
    INNER JOIN courses ON courses.id = materials.course_id
    INNER JOIN chapters ON chapters.id = materials.chapter_id
    WHERE
      courses.id = 39
  )
))