SQL Clone
SQLServerCentral is supported by Redgate
 
Log in  ::  Register  ::  Not logged in
 
 
 


how i can store marathi font in sql server


how i can store marathi font in sql server

Author
Message
gamit124
gamit124
Grasshopper
Grasshopper (10 reputation)Grasshopper (10 reputation)Grasshopper (10 reputation)Grasshopper (10 reputation)Grasshopper (10 reputation)Grasshopper (10 reputation)Grasshopper (10 reputation)Grasshopper (10 reputation)

Group: General Forum Members
Points: 10 Visits: 32
I am going to design a application having front end with VB6.0 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?
Lowell
Lowell
One Orange Chip
One Orange Chip (28K reputation)One Orange Chip (28K reputation)One Orange Chip (28K reputation)One Orange Chip (28K reputation)One Orange Chip (28K reputation)One Orange Chip (28K reputation)One Orange Chip (28K reputation)One Orange Chip (28K reputation)

Group: General Forum Members
Points: 28409 Visits: 39963
your table needs to use nvarchar and not varchar fields to hold unicode data.
in addition, any parameters you are using also need to be nvarchar...so in .NET language, for example if you declared a SQL Parameter that was not nvarchar, the parameter would convert your data to question marks, and then store it in a field that ahd the ability to store it correct.



Dim pAgencyAlias As New SqlParameter("@AgencyAlias", SqlDbType.VarChar, 30)
--should be
Dim pAgencyAlias As New SqlParameter("@AgencyAlias", SqlDbType.NVarChar, 30)



example of accidental implicit conversion:

/*--Results
(No column name) (No column name)
??/?? ??/??
(No column name) (No column name)
??/?? 汉字/漢字
*/
declare @var varchar(10),
@nvar nvarchar(10)
SELECT @var = ' 汉字/漢字' ,@nvar = ' 汉字/漢字'
SELECT @var,@nvar
SELECT @var = N' 汉字/漢字' ,@nvar = N' 汉字/漢字'
SELECT @var,@nvar



Lowell

--
help us help you! If you post a question, make sure you include a CREATE TABLE... statement and INSERT INTO... statement into that table to give the volunteers here representative data. with your description of the problem, we can provide a tested, verifiable solution to your question! asking the question the right way gets you a tested answer the fastest way possible!

gamit124
gamit124
Grasshopper
Grasshopper (10 reputation)Grasshopper (10 reputation)Grasshopper (10 reputation)Grasshopper (10 reputation)Grasshopper (10 reputation)Grasshopper (10 reputation)Grasshopper (10 reputation)Grasshopper (10 reputation)

Group: General Forum Members
Points: 10 Visits: 32
its not working
Lowell
Lowell
One Orange Chip
One Orange Chip (28K reputation)One Orange Chip (28K reputation)One Orange Chip (28K reputation)One Orange Chip (28K reputation)One Orange Chip (28K reputation)One Orange Chip (28K reputation)One Orange Chip (28K reputation)One Orange Chip (28K reputation)

Group: General Forum Members
Points: 28409 Visits: 39963
gamit124 (4/19/2013)
its not working


Remember we are not sitting behind you, looking over your shoulder.
i have no idea what is working or not working.

If you want help with that, you'd need to post the TSQL code you are using so we can paste it in our own SSMS and offer improvements.

the code i pasted certainly works and demonstrates that the field must be nvarchar AND the assignment must follow the N'value' format in order to preserve the values.

Lowell

--
help us help you! If you post a question, make sure you include a CREATE TABLE... statement and INSERT INTO... statement into that table to give the volunteers here representative data. with your description of the problem, we can provide a tested, verifiable solution to your question! asking the question the right way gets you a tested answer the fastest way possible!

Go


Permissions

You can't post new topics.
You can't post topic replies.
You can't post new polls.
You can't post replies to polls.
You can't edit your own topics.
You can't delete your own topics.
You can't edit other topics.
You can't delete other topics.
You can't edit your own posts.
You can't edit other posts.
You can't delete your own posts.
You can't delete other posts.
You can't post events.
You can't edit your own events.
You can't edit other events.
You can't delete your own events.
You can't delete other events.
You can't send private messages.
You can't send emails.
You can read topics.
You can't vote in polls.
You can't upload attachments.
You can download attachments.
You can't post HTML code.
You can't edit HTML code.
You can't post IFCode.
You can't post JavaScript.
You can post emoticons.
You can't post or upload images.

Select a forum

































































































































































SQLServerCentral


Search