title: Getting an error using inner join
body: <p>My query</p>
  
  <pre><code>$con=mysqli_query($sql,"(SELECT  Church Name, Class, Student Name, Mark FROM Church_details INNER JOIN Class_details ON Church_details.Church id=Class_details.Church id GROUP BY Class ORDER BY Student Name)")
  </code></pre>
  
  <p>I'm getting error like this:</p>
  
  <pre><code>   You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'id=Class_details.Church id GROUP BY Class ORDER BY Student Name)' at line 1
  </code></pre>