Click here to monitor SSC
SQLServerCentral is supported by Redgate
 
Log in  ::  Register  ::  Not logged in
 
 
 


How to Store and Retrive the Non English (some other language) Characters in Database.


How to Store and Retrive the Non English (some other language) Characters in Database.

Author
Message
sumit.sharma
sumit.sharma
Forum Newbie
Forum Newbie (5 reputation)Forum Newbie (5 reputation)Forum Newbie (5 reputation)Forum Newbie (5 reputation)Forum Newbie (5 reputation)Forum Newbie (5 reputation)Forum Newbie (5 reputation)Forum Newbie (5 reputation)

Group: General Forum Members
Points: 5 Visits: 10
Hey Guys

I want to store and retrieve the Non English Characters (some other language) in the Database. What i know is while storing it gets stored in the UNICODE format in nvarchar and nchar datatypes. I dont have any idea apart from this.

Can somebody help me in this. If somebody can give me step by step explanation of this then it would be of great help.

Regards
Sumit
vidhya sagar
vidhya sagar
SSC-Addicted
SSC-Addicted (496 reputation)SSC-Addicted (496 reputation)SSC-Addicted (496 reputation)SSC-Addicted (496 reputation)SSC-Addicted (496 reputation)SSC-Addicted (496 reputation)SSC-Addicted (496 reputation)SSC-Addicted (496 reputation)

Group: General Forum Members
Points: 496 Visits: 620
Hi Sumit,

You are right to insert a character other than english you need to declare the column as nvarchar and while inserting the data also use N infront of the data to inform SQL Server as unique character. An example is shown below, here im inserting russian character

CREATE TABLE #tmp(description NVARCHAR(15))
INSERT #tmp VALUES (N'Добро')




SELECT * FROM #tmp
description
---------------
Добро

(1 row(s) affected)



I hope this would hel you!


Regards..Vidhya Sagar
SQL-Articles
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