Interesting query request for PeopleSoft
Posted in 2009
Good Afternoon, IDS v10FC8 HPUX 11.23 I have a developer that's trying to create a query which uses an expression in the group by. The group by 1 works (obviously). If he uses the expression in the group by it does not work. Is this possible? This will become a psoft query and you can't use '1' in the group by in psoft since it actually pulls in the expression. I've asked if he can parse out just the "month". Here's the query: select month(creation_dt) || '/' || year(creation_dt) as month, count(*) as count_of_exceptions from ps_cxmtchexcptnarc a where a.created_dttm = (select min(b.created_dttm) from ps_cxmtchexcptnarc b where b.business_unit = a.business_unit and b.voucher_id = a.voucher_id and b.voucher_line_num = a.voucher_line_num and b.match_rule_id = a.match_rule_id and b.created_dttm <= today+1) group by month(creation_dt) || '/' || year(creation_dt) as month order by 1 Any ideas would be greatly appreciated. Thanks for taking the time!