Hebrew encoding in sql server2005

后端 未结 1 550
失恋的感觉
失恋的感觉 2020-12-21 17:24

i try this code in sql server 2005

declare @userName nvarchar(50)
set @userName=\'איש2\'    
print @userName

but i get this



        
相关标签:
1条回答
  • 2020-12-21 17:50

    Use the N prefix so the string literal is interpreted as unicode not char under the code page of whatever your database's default collation is

    declare @userName nvarchar(50)
    set @userName=N'איש2'    
    print @userName
    
    0 讨论(0)
提交回复
热议问题