[mapserver-commits] [MapServer/MapServer] d91fec: Fixes for using none ascii characters in Sql Serve...

Krister Wicksell noreply at github.com
Tue Sep 29 00:49:25 PDT 2020


  Branch: refs/heads/master
  Home:   https://github.com/MapServer/MapServer
  Commit: d91fec44118f7c421355e8632d20bd96c7152887
      https://github.com/MapServer/MapServer/commit/d91fec44118f7c421355e8632d20bd96c7152887
  Author: Krister Wicksell <krister.wicksell at sokigo.com>
  Date:   2020-09-29 (Tue, 29 Sep 2020)

  Changed paths:
    M mapmssql2008.c
    M mapserver.h
    M mapstring.cpp

  Log Message:
  -----------
  Fixes for using none ascii characters in Sql Server connection strings, queries and results (#6150)

* Fix encoding issues in SQL Server plugin

There has been an encoding problem in the SQL Server plugin. Queries used SQLExecDirect instead of SQLExecDirectW making the plugin dependent on that the systems locale matched the encoding of the map-file. For Swedish characters on Swedish Windows the map file needed to be in ISO-8859-1 but other connections such as PostGIS reguire the map-file to be in UTF-8. So combining different type of connections was a problem. The plugin was also using a bad pattern when reading attributes from SQL Server, see https://docs.microsoft.com/en-us/sql/relational-databases/native-client/features/odbc-driver-behavior-change-when-handling-character-conversions?view=sql-server-ver15

* Update mapmssql2008.c

Added support for unicode characters in SQL Server connection string.

* Fixed casting in msConvertWideStringFromUTF8.




More information about the mapserver-commits mailing list