1

I am trying to insert square root symbol into my SQL Server database from an ASP.NET page. The radical symbol (√) gets inserted as letter v instead.

Where could I be going wrong?

Thanks for your assistance.

Rahul Nikate
  • 6,192
  • 5
  • 42
  • 54
Raphael Mutiso
  • 63
  • 1
  • 11
  • Please edit your question to include the type of the field you're inserting into and collation information, as well as the code you're using to perform the insert – ardila Jul 12 '16 at 09:06

2 Answers2

1

Your database column type should be nVarChar to insert Unicode characters.

Also you need to pass values like below:

cmd.Parameters.Add("@ColumnName", SqlDbType.NVarChar, 1024).Value = txtName.Text;
Rahul Nikate
  • 6,192
  • 5
  • 42
  • 54
0

Column in your table should be able to store unicode characters, try change the type to nvarchar

and while inserting you should use N symbol before the value

let say the column name is square_root and table is test

insert into test(square_root) values(N'√25 = 5')

enter image description here

Sachu
  • 7,555
  • 7
  • 55
  • 94