I'm getting a syntax error in MySQL query. Is MySQL and SQL server work differently? Can anyone suggest, what is wrong and where ?
select b.component, d.matter, d.bug, d.timestamp, d.os
from bugs.profiles p, ops_reports.BPR_TAG_DATA d
left join (Select * from bugs where product='test') b
on d.bug=b.bug_id
where d.tagid = 6
and timestamp between "2014-04-21" and "2014-04-24"
and login_name like 'test'
and p.userid = d.user
Error Message 24/04/2014 23:14:10 0:00:00.037 MySQL Database Error: 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 'Select * from bugs where product='Conversions') as b on (d.bu 1 0
JOINkeyword in place of the comma, and relocate join predicates from the WHERE clause to an appropriate ON clause. Also, best practice is to qualify all column references. (e.g.and b.timestamp BETWEEN... easier for the reader to decipher AND avoids query breaking with "ambiguous column" error when column of the same name later added to another table