Odd characters showing small table after using tableDiff

前端 未结 2 437
生来不讨喜
生来不讨喜 2021-01-26 00:47

SQLServer tabeDiff is being used to sync DB\'s. The  character has been found in the destination table. I can find nothing on this anywhere, has anyone experienced this? Here i

2条回答
  •  清酒与你
    2021-01-26 01:30

    The character ® has decimal code value 174 and is therefore not an ASCII character which all have code values in range of 0 to 127.

    ® is the character ® stored in the text file encoded with Unicode encoding UTF-8, but displayed as ANSI character using code page Windows 1252 or ISO 8859-1.

    So the export of the differences is done fine and the created file (text file?) is okay. You only have to open this UTF-8 encoded file in your text editor / viewer by using UTF-8 if editor / viewer does not automatically detect the UTF-8 encoding.

    You can insert at top of the text file  which is hexadecimal EF BB BF which is the byte order mark (BOM) for UTF-8. That would help text editors / viewers to faster detect that the text file is encoded in UTF-8. But some applications do not interpret those 3 bytes at beginning of a text file as BOM.

    Now with knowing that your problem is caused by different encoding of non ASCII characters, you can search for related pages. See for example Description of storing UTF-8 data in SQL Server. I suggest to search with the words Unicode UTF-8 SQL Server.

提交回复
热议问题