title: How can i write sql code to bring values from another table and use count function?
body: <p>My quesiton is :</p>
  
  <p>Find the names of all classes that either meet in room R128 or have three or more students enrolled.</p>
  
  <p>and my code is :</p>
  
  <pre><code>SELECT cname,count(cname) as total FROM lab5comblm258.enrolled 
  where cname= any ( SELECT _name FROM lab5comblm258.class
  WHERE room='R128' )
  group by cname
  ;
  </code></pre>
  
  <p><a href="https://i.stack.imgur.com/XCEKJ.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/XCEKJ.png" alt="enter image description here"></a></p>
  
  <p>What Must I add to my code?</p>