Guest_imported
New member
- Jan 1, 1970
- 0
SELECT timestamp, report_type, max(DATA_VALUE) FROM DWHS.MAINSTREAM_GAMES_REPORTS
where timestamp >= trunc(sysdate - 7) and report_type = 'hrts_peak_user'
group by timestamp, report_type
above is my statement. What i would like is to add another field to the select (data_name before the max). My prob is then i have to add data_name to the group by list. This inevitably shows me every instance instead of just the max(data_value). any ideas
where timestamp >= trunc(sysdate - 7) and report_type = 'hrts_peak_user'
group by timestamp, report_type
above is my statement. What i would like is to add another field to the select (data_name before the max). My prob is then i have to add data_name to the group by list. This inevitably shows me every instance instead of just the max(data_value). any ideas