1

I am trying to import this data here with special characters such as ä and ö (umlauts). When I import data in SQL Server Management Studio, I get the following error

enter image description here

The output char buffer is too small to contain the decoded characters, encoding 'Unicode (UTF-9)'fallback 'System.Text.DecoderReplacementFallback'. Parameter name: chars (mscorlib)

so how can I import the data with umlauts to SSMS? What is causing the error and how to overcome it?

Community
  • 1
  • 1
hhh
  • 50,788
  • 62
  • 179
  • 282
  • 3
    ensure your column type that the data is going into can support unicode. Look for data-types prefixed with "N" like NVARCHAR or NCHAR. Can you provide the schema for the table you're trying to import to? You can find this by running `SELECT TABLE_NAME , COLUMN_NAME , DATA_TYPE , CHARACTER_MAXIMUM_LENGTH FROM [information_schema].[columns] where table_name = 'myTableName'` – EMUEVIL May 11 '17 at 14:27
  • @EMUEVIL I import the data from a CSV file. – hhh May 11 '17 at 14:29
  • 2
    Maybe silly question, but did you check the Unicode box in the General window when you made your Flat File connection? And as @EMUEVIL said, make sure your target columns are of a type that can accept unicode data (prefixed with N like NVARCHAR instead of VARCHAR). – Jacob H May 11 '17 at 14:34
  • 3
    @hhh I'm not talking about the format of the CSV. You can't import unicode data into non-unicode table columns. – EMUEVIL May 11 '17 at 14:42
  • You may picked wrong Locale/code page from the drop down list in the import/export wizard. – Wendy May 11 '17 at 16:04

0 Answers0