11 February 2018

personalHobbies

My solution:
CREATE PROCEDURE personalHobbies() 
BEGIN 
  SELECT name 
  FROM   people_hobbies 
  WHERE  hobbies LIKE "%sports%" 
         AND hobbies LIKE "%reading%" 
  ORDER  BY name; 
END 

interestClub

My solution:
CREATE PROCEDURE interestClub() 
  SELECT name 
  FROM   people_interests 
  WHERE  interests && interests LIKE "%drawing%" 
         AND interests && interests LIKE "%reading%" 
  ORDER  BY name