hi, my application generates an uniqueidentifier in mssql which then used to generate a querystring for link for user to click. Page user lands after that click do something with user but first validates if such uniqueidentifier exists to avoid heavy stored procedure with small check. I want to improve it by checking whether querystring passed is actually a Guid.
My first question is whether .net Guid and MSSQL uniqueidentifier are of the same type and length and second one if there any better way to test whether some string is a Guid except
try { new Guid("somevalue") } catch (Exception) {}