Welcome to the LimeSurvey Community Forum

Ask the community, share ideas, and connect with other LimeSurvey users!

Problem with portuguese char MS-SQL

  • sazevedo
  • sazevedo's Avatar Topic Author
  • Offline
  • New Member
  • New Member
More
4 years 3 months ago #191815 by sazevedo
Problem with portuguese char MS-SQL was created by sazevedo
Hello,

We have installed the latest version of limesurvey with this characteristics:
PHP Version 7.2.24
System Linux
MS-SQL 2014

When we create a survey with portuguese char like çã the char appears ok, but if we upload an image this char changes to ção or they disappear.
Can you help us?

thanks in advance
The topic has been locked.
More
4 years 3 months ago #191934 by fvanderstarre
Replied by fvanderstarre on topic Problem with portuguese char MS-SQL
You need to enable UTF-8 encoding on your MS-SQL server.
See " docs.microsoft.com/en-us/sql/relational-...iew=sql-server-ver15 " .
I don't know if that's possible for an existing database though.
Good luck!
The topic has been locked.
More
4 years 3 months ago #191947 by Matadeleo
Replied by Matadeleo on topic Problem with portuguese char MS-SQL
Code:
USE master;
GO
ALTER DATABASE MyDatabase
COLLATE utf8mb4_unicode_ci;
GO
The topic has been locked.
  • sazevedo
  • sazevedo's Avatar Topic Author
  • Offline
  • New Member
  • New Member
More
4 years 3 months ago #192029 by sazevedo
Replied by sazevedo on topic Problem with portuguese char MS-SQL
Hi Matadeleo,

Unfortunately that collate is only for MySQL, not SQL server. :(
The following user(s) said Thank You: DenisChenu
The topic has been locked.
  • sazevedo
  • sazevedo's Avatar Topic Author
  • Offline
  • New Member
  • New Member
More
4 years 3 months ago #192030 by sazevedo
Replied by sazevedo on topic Problem with portuguese char MS-SQL
Hi Fvanderstarre,

We are using the latin general.
It works ok if you don't upload images
The topic has been locked.
  • DenisChenu
  • DenisChenu's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
4 years 3 months ago #192038 by DenisChenu
Replied by DenisChenu on topic Problem with portuguese char MS-SQL
We use nvarchar for mssql : docs.microsoft.com/en-us/sql/t-sql/data-...iew=sql-server-ver15

github.com/LimeSurvey/LimeSurvey/blob/a5.../MssqlSchema.php#L11

Then some solutions : you use an old version of LimeSuvey or your server didn't accept nvarchar or transfert between SQL server and web server broke collation

Assistance on LimeSurvey forum and LimeSurvey core development are on my free time.
I'm not a LimeSurvey GmbH member, professional service on demand , plugin development .
I don't answer to private message.
The topic has been locked.
  • sazevedo
  • sazevedo's Avatar Topic Author
  • Offline
  • New Member
  • New Member
More
4 years 2 months ago #192908 by sazevedo
Replied by sazevedo on topic Problem with portuguese char MS-SQL
Hi,

We've installed a new version with MySQL and the problem was solved.
The problem appears only with SQL server database.

Thank you for your help
The topic has been locked.
  • DenisChenu
  • DenisChenu's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
4 years 2 months ago #192910 by DenisChenu
Replied by DenisChenu on topic Problem with portuguese char MS-SQL
I use LimeSurvey on a mssql server and don't have issue with utf8 caracter with the last LTS version : github.com/LimeSurvey/LimeSurvey/commit/...24c1774493d86706233a
Please : always put the LimeSurvey version and build number

Assistance on LimeSurvey forum and LimeSurvey core development are on my free time.
I'm not a LimeSurvey GmbH member, professional service on demand , plugin development .
I don't answer to private message.
The topic has been locked.

Lime-years ahead

Online-surveys for every purse and purpose