How to store Marathi Character in SQL server?

I am going to design a application having front end with VB.Net and Back end with SQL SERVER in. And I want the complete interface of that application in marathi language.

when I enter the marathi character in data base and execute it, it shows "????????" like this.
What I do to enter and store the marathi character in Database?

 

September 19th, 2010 11:53am

You will need to use a Unicode data type (nvarchar or nchar).  In the case non-parameterized queries, you'll need to prefix the string with N to indicate a Unicode string.  Otherwise, characters are converted to the code page of the database default collation:

SELECT N'' AS Hello;

Hope this helps.

--

Free Windows Admin Tool Kit Click here and download it now
September 19th, 2010 1:35pm

Sir,

I am still facing the same problem. After using nvarchar or nchar it shows the '?????????' like this. Is their any different method to solve this problem. 

September 26th, 2010 6:42am

Are you saying in application it is showing ???? ? In that case check the locale? If you are seeing this behaviour in DB Check this

 

 

create table test(col nvarchar(22))
insert test SELECT N''
insert test SELECT ''
select *from test

BTB... Namaskar DAN... :)

 

Madhu

Free Windows Admin Tool Kit Click here and download it now
September 26th, 2010 10:37am

Thank you very much..
October 16th, 2013 1:51pm

I am getting error when i tried to save using c# code. in sql it works fine. how to write insert query the same written in c#

slc= Insert into test values(@Name);

slc.Parameters.Add("@Name", SqlDbType.NVarChar,22);

slc.Parameters[@Names].Value = textbox1.Text;

slc.ExecuteNonQuery();

Free Windows Admin Tool Kit Click here and download it now
March 13th, 2015 2:07pm

1) Don't piggyback on an old thread from 2010, but start a new thread. Preferrably in the appropriate forum.

2) Don't only say I am getting an error, but also include the error message in your post.

To be able to work with text in Marathi, I believe you need to have a collation with 90 or 100 in the name. (But using the wrong collation would not give an error message, only unexpected results when you work with the data.)

March 13th, 2015 6:20pm

This topic is archived. No further replies will be accepted.

Other recent topics Other recent topics