Guest User

Untitled

a guest
Jan 19th, 2019
87
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.36 KB | None | 0 0
  1. $stmt = $dbConn->prepare("SELECT * FROM
  2. (
  3. SELECT subject.id as 'SubjectID', subject.title, subject.menu_image, video.id as 'VideoID' FROM video LEFT JOIN subject ON video.subject_id = subject.id WHERE video.is_active = 1 AND video.activation_date <= CURDATE() ORDER BY subject.id, video.title
  4. ) as tmp
  5. group by SubjectID");
Add Comment
Please, Sign In to add comment