In the warning image I have a report definition which have guardrail warnings. I removed sort order and set sort type to blank.I can't save it because same settings appear again but when I check the "do not display group heading" I can save. What is the reason?
I tried implementing your use-case in-house with an OOTB report. I was able to save the report definition rule without any guardrail warnings.
So, I believe you must have a column summarized. In that case, the column which is summarized would be heading column of that group and couldn't have any sorting arrangement while other columns can have it or not.
Also as per my understanding, In Pega 7, inside report definition > report viewer tab, if “Do not display group headings” checkbox is checked, Pega does not mandate any sort sequence and sorting can be performed on aggregates as required. Therefore, check the “Do not display group headings” checkbox to override the sort sequence enforced by Pega. When this is selected, the user can sort the report in any way desired.
Sort order is populated automatically on the group by columns to increase the performance of aggregate calculations.