[Vtigercrm-developers] Installation and non-ASCII characters in thedefault data populator

Zygmuntowicz Michal m.zygmuntowicz at onet.pl
Mon Dec 16 13:56:49 GMT 2013


Maybe the problem arises because DefaultDataPopulator uses the 'query' method
instead of the 'pquery' call with bound parameters, so actual data values get embedded
into a query string and therefore SET NAMES utf8 is required to make it work correctly.

Most other queries for inserting/updating data during normal workflow use pquery
and bound parameters and calling/omitting SET NAMES utf8 may have no impact there.

Another idea may be that during installation not all default variables have correct
values and SET NAMES utf8 is not called when it should be, so UTF-8 characters
get inserted into the database incorrectly.


From: Zygmuntowicz Michal 
Sent: Monday, December 16, 2013 12:41 PM
To: vtigercrm-developers at lists.vtigercrm.com 
Subject: [Vtigercrm-developers] Installation and non-ASCII characters in thedefault data populator


Hello,

during Vtiger 6 installation Polish currency and language names
display non-ASCII characters incorrectly (I guess the problem relates
to other languages as well). I have reviewed the ticket http://trac.vtiger.com/cgi-bin/trac.cgi/ticket/7784
and added an approtiate comment.

The problem seems to be a missing call to SET NAMES utf8
while populating default data in the modules/Users/DefaultDataPopulator.php file.
I guess it should be called automatically, but it does not happen.
If I insert the call manually, the default data gets populated correctly.

Maybe it is somehow related to mysql server settings. My settings are:

Server characterset:    latin1
Db     characterset:    utf8
Client characterset:    utf8
Conn.  characterset:    utf8

I create a database by hand before starting installation with the utf8 character set,
but the default server character set is latin1 - maybe this causes the problem
and requires SET NAMES utf8.

Regards,
Michal Zygmuntowicz




--------------------------------------------------------------------------------


_______________________________________________
http://www.vtiger.com/
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.vtigercrm.com/pipermail/vtigercrm-developers/attachments/20131216/afed5c4c/attachment.html>


More information about the vtigercrm-developers mailing list