How can I get from this SQL Server varbinary:
0x63C34D6BCAD555EB64BF7E848D02C376
To this varchar?
'63C34D6BCAD555EB64BF7E848D02C376'
declare @B varbinary(max) = 0x63C34D6BCAD555EB64BF7E848D02C376
declare @C varchar(35)
set @C = stuff(upper(sys.fn_varbintohexstr(@B)), 1, 2, '')
select @C
Result:
63C34D6BCAD555EB64BF7E848D02C376
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With