SQL Script Package Fails with French characters.
Davy Mitchell
Posts: 19
Hi There,
I have a French SQL Script which has acute accents in it. The Script (ANSI) executes correctly on SQL Server. When Packaged (ver6) it fails. Full trace below but the key bit is 'AUTORITE NT\SERVICE R�SEAU' - the square should be an e acute - 'AUTORITE NT\SERVICE RÉSEAU'.
Do I need to save in Unicode or..... ?
Thanks in advance
Thanks,
Davy Mitchell
<SQLError Package="French_XP_SRSS"><Error>Windows NT user or group 'AUTORITE NT\SERVICE R�SEAU' not found. Check the name again.</Error><Assembly>French_XP_SRSS</Assembly><Package>Package1.resx</Package><Batch>Batch2</Batch><SQL>CREATE LOGIN [AUTORITE NT\SERVICE R�SEAU] FROM WINDOWS WITH DEFAULT_DATABASE=[master], DEFAULT_LANGUAGE=[us_english]</SQL></SQLError>
I have a French SQL Script which has acute accents in it. The Script (ANSI) executes correctly on SQL Server. When Packaged (ver6) it fails. Full trace below but the key bit is 'AUTORITE NT\SERVICE R�SEAU' - the square should be an e acute - 'AUTORITE NT\SERVICE RÉSEAU'.
Do I need to save in Unicode or..... ?
Thanks in advance
Thanks,
Davy Mitchell
<SQLError Package="French_XP_SRSS"><Error>Windows NT user or group 'AUTORITE NT\SERVICE R�SEAU' not found. Check the name again.</Error><Assembly>French_XP_SRSS</Assembly><Package>Package1.resx</Package><Batch>Batch2</Batch><SQL>CREATE LOGIN [AUTORITE NT\SERVICE R�SEAU] FROM WINDOWS WITH DEFAULT_DATABASE=[master], DEFAULT_LANGUAGE=[us_english]</SQL></SQLError>
Comments
Unfortunately this is an issue with ANSI scripts, we already have a bug open for this case (SC-4198). You should be able fix this issue by encoding the scripts differently, but it seems that you cannot choose the script encoding through the UI. - I have just logged this as a bug with SQL Packager (SPA-505).
However, you can set the script encoding if you run Packager from the command line. You will be able to use your UI project file with the addition of the /scriptencoding option.
Something like: SQLPackager /pr:"MyProjectFile" /makeexe /scriptencoding:Unicode
You can find out more information on using the command line interface in the helpfile:
http://www.red-gate.com/supportcenter/P ... 20Packager
I hope this is helpful.