title: SQL query error #1064
body: <p>So I have this query:</p>
  
  <pre><code>SELECT 
     t1.password 
  FROM Session AS t1 
  INNER JOIN Locations AS t2 ON 
      t2.id = t1.location_id AND 
      SQRT( POWER( CONVERT(t2.longitude,float(10)) - 132.456, 2) + 
          POWER( CONVERT(t2.latitude,float(10)) - 132.456, 2) ) &lt; 100 
  WHERE t1.end_distribution = 0 AND t1.end_session = 0
  </code></pre>
  
  <p>and I get this:</p>
  
  <blockquote>
    <p>1064 - You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'float(10)) - 132.456, 2) + POWER( CONVERT(t2.latitude,float(10)) - 132.456, 2) )' at line 13 </p>
  </blockquote>