1
A1
1000
<
If you have the option of using for-each-group, I'd definitely use that over Muenchian grouping...
Fiddle: http://xsltfiddle.liberty-development.net/jxNakzX
If you truly want to hard code the "A" -> A1, A2 and "B" -> B1, B2 mapping, you could use xsl:key and not group at all...
Fiddle: http://xsltfiddle.liberty-development.net/jxNakzX/1