The attached workbook seems to do what you want it to be doing. However, one possible option (say that you wanted Hold first and then Err) would be to right click on test on the rows shelf and select Sort... Then, sort the dimensions as desired.
Hope this helps!
IF [A] = [Parameter1] then "1"
ELSEIF [A] = [Parameter2] then "2" END
I used this formula and did manual sort on the calculated field.