Click here to monitor SSC
SQLServerCentral is supported by Red Gate Software Ltd.
 
Log in  ::  Register  ::  Not logged in
 
 
 
        
Home       Members    Calendar    Who's On


Add to briefcase

Data Encoding Problem.. Need help from you guys! Expand / Collapse
Author
Message
Posted Tuesday, November 15, 2005 8:53 AM
Forum Newbie

Forum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum Newbie

Group: General Forum Members
Last Login: Tuesday, November 15, 2005 8:44 AM
Points: 1, Visits: 1
Hi guys! I created a application before using classic ASP (www.adabpixel.com). This simple application saves arabic data, but the main problem I didnt notice is that it is saving the data in windows-1252 encoding. As a result, my data are all in unreadable format (ÇáÈßÓá ááÝäæä ÇáÑÞãíÉ). Im trying to reconstruct the whole application in .NET but the problem is I cant show the correct data. I already made my globalization settings to windows-1256 & windows-1252 (Vice Versa).

Is there a way I can change the encoding through T-SQL? I even tried copying it to another database with arabic as its standard format.

Hoping for your immediate reply on this matter.



Post #237225
Posted Friday, November 18, 2005 8:00 AM
SSChampion

SSChampionSSChampionSSChampionSSChampionSSChampionSSChampionSSChampionSSChampionSSChampionSSChampion

Group: General Forum Members
Last Login: Friday, May 18, 2007 3:36 PM
Points: 10,039, Visits: 1
No one has responded to this topic yet. Even if you don't have a complete answer, the original poster will appreciate any thoughts you have!
Post #238114
Posted Monday, November 21, 2005 12:18 PM
SSC Veteran

SSC VeteranSSC VeteranSSC VeteranSSC VeteranSSC VeteranSSC VeteranSSC VeteranSSC Veteran

Group: General Forum Members
Last Login: Friday, August 15, 2014 10:18 AM
Points: 228, Visits: 241
You could try the bulk copy and set the codepage there.
Post #238627
Posted Thursday, February 9, 2006 1:24 PM
Valued Member

Valued MemberValued MemberValued MemberValued MemberValued MemberValued MemberValued MemberValued Member

Group: General Forum Members
Last Login: Monday, March 23, 2009 9:10 AM
Points: 67, Visits: 6
If you write the raw data into a text file, you can use iconv to do a simple conversion.

Check that your iconv supports the proprietary Microsoft Arabic codepage, if you want that one, like so:

$ iconv -l | grep 1256
CP1256 MS-ARAB WINDOWS-1256

Aha, my iconv supports the proprietary Microsoft page.

So, cat YourData.txt | iconv -f CP1256 -t UTF-8 > YourData_fixed_UTF8.txt

and you should get a nice UTF-8 version (UTF-8 is the version of Unicode used mostly on the Internet).

Or, if your source was actually encoded in the proprietary Microsoft DOS Arabic codepage, 720, use -- well, my iconv doesn't support 720, so I'm not sure.

Microsoft has a beta for Arabic codepage conversion

http://www.microsoft.com/middleeast/arabicdev/beta/converter/

but it's beta, probably neither Free nor Open Source, the download does not seem to include any documentation (there is a readme which says to run the setup, which I didn't do), and my guess is it does no more (and much less) than iconv.


Post #257232
Posted Wednesday, May 14, 2008 10:09 AM
Forum Newbie

Forum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum Newbie

Group: General Forum Members
Last Login: Friday, August 30, 2013 3:26 AM
Points: 2, Visits: 18
Years pass by months pass by ,,no one gives any straight forward answer for this Collation problem while running BCP for the error ::Error = [Microsoft][ODBC SQL Server Driver][SQL Server]Code page 720 is not supported by SQL Server
Post #500692
Posted Monday, October 27, 2008 7:52 AM
Forum Newbie

Forum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum Newbie

Group: General Forum Members
Last Login: Thursday, December 2, 2010 2:04 AM
Points: 1, Visits: 68
try to add the switch -c850 or -craw it worked for me
Good luck
Post #592114
« Prev Topic | Next Topic »

Add to briefcase

Permissions Expand / Collapse