June 21, 2008 at 7:38 am
I have SQL Server database table with International characters. Is there any way I can bcp out the table into csv file in UTF-8 format?
June 23, 2008 at 6:08 am
rkjayaraj (6/21/2008)
I have SQL Server database table with International characters. Is there any way I can bcp out the table into csv file in UTF-8 format?
I have the same Problem, but my Destination is TXT.
declare @pfad varchar(8000)
set @pfad = 'bcp "select * from I_Kunden_EMail with (nolock)" queryout
"\\Server\export\Emailadressen\email'+convert(varchar(10),getdate(),112)+'.txt" -T -t; -w '
exec xp_cmdshell @pfad
Which Parameters I need für UTF-8
June 23, 2008 at 8:23 am
i get an answer in on an other board.
The Parameters are : -c -C65001
March 8, 2010 at 9:15 pm
AndreT78 (6/23/2008)
i get an answer in on an other board.The Parameters are : -c -C65001
http://msdn.microsoft.com/en-us/library/ms162802.aspx
Micorsoft siaid "SQL Server does not support code page 65001 (UTF-8 encoding)."
No luck for me.
March 26, 2011 at 12:11 pm
UTF-8 is not supported anymore for SQL Server 2008 (R2?), see http://msdn.microsoft.com/en-us/library/ms188365.aspx and go to CODEPAGE.
There's more info on the web as to why, but in short that's why it worked on SQL Server 2005 but not 2008 (R2).
March 30, 2011 at 12:02 am
the thread is from 2008
May 17, 2011 at 9:25 pm
It is good to learn about how to bcp out the table into csv file in UTF-8 format. Thanks for posting the link to the answer.
Leo
Website: How to Make Money Online Resources
August 3, 2011 at 6:25 am
Hey ,
Alter native of UTF8 support in SQLSERVER 2008 R2
1. if u are importing multiligual file keep this in UTF16(UCS2[LE]) format rather than UTF8 because BCP import dont support UTF8 code page in MS SQLSERVER R2.
2.table where u importing multiligual character, column should be NVARCHAR type
Follow BCP Command for import data
bcp [DATABASE].[dbo].[tablename] in TestBCP.txt(UTF16 format) -S<SERVER> -U<USRName> -P<PWD> -C -w
option -w support widecharacter(after 256)
plz let me know if helps
thanks
Shashi
Viewing 8 posts - 1 through 7 (of 7 total)
You must be logged in to reply to this topic. Login to reply