We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents 36d38f4 + bdadf63 commit 5a8b922Copy full SHA for 5a8b922
1 file changed
sp_QuickieStore/sp_QuickieStore.sql
@@ -5657,7 +5657,16 @@ OUTER APPLY
5657
qsp.last_execution_time DESC
5658
) AS qp
5659
ORDER BY
5660
- o.impact_score DESC
+ o.impact_score DESC,
5661
+ ' +
5662
+ CASE LOWER(@sort_order)
5663
+ WHEN 'duration' THEN N'o.duration_share'
5664
+ WHEN 'physical reads' THEN N'o.physical_reads_share'
5665
+ WHEN 'writes' THEN N'o.writes_share'
5666
+ WHEN 'memory' THEN N'o.memory_share'
5667
+ WHEN 'executions' THEN N'o.executions_share'
5668
+ ELSE N'o.cpu_share'
5669
+ END + N' DESC
5670
OPTION(RECOMPILE);' + @nc10;
5671
5672
IF @debug = 1
0 commit comments