Hi folks,
[MySQL][ODBC 3.51 Driver][mysqld-5.0.24-community-nt]Every derived table must have its own alias
is the ERROR displayed and my QUERY is
SELECT product FROM (select distinct product from brucedata where (styledesc like 'BRETTON' or styledesc like 'miscellaneous') and series like 'AW' union all select distinct product from brucedata where (styledesc like 'HARTFORD' or styledesc like 'miscellaneous') and series like 'AW' union all select distinct product from brucedata where (styledesc like 'MONTERO' or styledesc like 'miscellaneous') and series like 'AW') group by product having count(product) = 3
I am trying to add aliases but it just doesn't work. Can someone show me the correct way to add aliases, so the query works?
Thanks
[MySQL][ODBC 3.51 Driver][mysqld-5.0.24-community-nt]Every derived table must have its own alias
is the ERROR displayed and my QUERY is
SELECT product FROM (select distinct product from brucedata where (styledesc like 'BRETTON' or styledesc like 'miscellaneous') and series like 'AW' union all select distinct product from brucedata where (styledesc like 'HARTFORD' or styledesc like 'miscellaneous') and series like 'AW' union all select distinct product from brucedata where (styledesc like 'MONTERO' or styledesc like 'miscellaneous') and series like 'AW') group by product having count(product) = 3
I am trying to add aliases but it just doesn't work. Can someone show me the correct way to add aliases, so the query works?
Thanks