In version 1.0.1, the order did not matter. With current head, though, -N has to occur before -T. Example follows.
$ xml sel -T -N D="urn:schemas-microsoft-com:office:spreadsheet" -t -m '//D:Worksheet' -v '@D:Name' -o ' ' -v 'count(D:Table[1]/D:Row[1]/D:Cell)-2' -n excel.xml
Undefined namespace prefix
xmlXPathCompiledEval: evaluation failed
runtime error: element for-each
Failed to evaluate the 'select' expression.
$ xml sel -N D="urn:schemas-microsoft-com:office:spreadsheet" -T -t -m '//D:Worksheet' -v '@D:Name' -o ' ' -v 'count(D:Table[1]/D:Row[1]/D:Cell)-2' -n suivi-excel.xml
…works…
Right, I broke this in 84e69101 (a bit after 1.1.0) when refactoring the edParseNSArr and selParseNSArr into parseNSArr.
Now fixed in commit 54bb4f7bb76ebf6942deef092cc4eff2c6d70b16