SQL Server: converting UniqueIdentifier to string in a case statement
It is possible to use the convert function here, but 36 characters are enough to hold the unique identifier value:
convert(nvarchar(36), requestID) as requestID
Edit: yes, as noted in the comments, char, or nchar, or any function that can properly manipulate ASCII character tables would do the trick. Then, my excuse is that I usually work in a multilingual/multialphabet environment, and the rule is to go for nvarchar, always. That's my no-brainer way of doing things, sorry. And, if one of these days, some database software starts to generate unique identifier with non-ASCII elements, I will be ready.
I think I found the answer:
convert(nvarchar(36), RequestID)
Here's the link where I found this info:
http://msdn.microsoft.com/en-us/library/ms187928.aspx