Have checked your code now..
You have used DISTINCT in all individual SELECT statement and UNION / UNION ALL interchangeably.
Since you haven't provided the results, I would request you to
1. Remove DISTINCT in all individual statements
2. Replace UNION ALL with UNION
And try it out once.
Main Topics
Browse All Topics





by: joaoalmeidaPosted on 2009-11-06 at 01:32:33ID: 25757764
Try to have the columns in the same position with the same name.
For instance you have
s.create_time in first select
s.update_time in second select
and CreateTime in the second part of the query.
Regards,
Joao