OSCOMMERCE SUPPORT CALL 702-453-3332

 

Help - Search - Members - Calendar
Full Version: Problem in Cyrillic categoy names
osCommerce Community Support Forums > osCommerce Online Merchant v2.x > Contributions / Add-Ons > Languages and Zones
Antima
Hi everybody
Yesterday i created my online shop but unfortunately I'm getting an error message when trying to put a description in Bulgarian on the product categories

the funny part is that only 3 characters in Cyrillic van be displayed .. otherwise I'm meting this error message

1406 - Data too long for column 'categories_name' at row 1
update categories_description set categories_name = 'Касови Апарати' where categories_id = '23' and language_id = '4'

[TEP STOP]

please can anyone help me
IPSATS
QUOTE (Antima @ Jan 17 2008, 04:55 AM) *
Hi everybody
Yesterday i created my online shop but unfortunately I'm getting an error message when trying to put a description in Bulgarian on the product categories

the funny part is that only 3 characters in Cyrillic van be displayed .. otherwise I'm meting this error message

1406 - Data too long for column 'categories_name' at row 1
update categories_description set categories_name = 'Касови Апарати' where categories_id = '23' and language_id = '4'

[TEP STOP]

please can anyone help me


You need to change the structure of the table for 'categories_name'
there is the SQL command, you need to use wink.gif

ALTER TABLE `categories_description` CHANGE `categories_name` `categories_name` VARCHAR( 64 ) CHARACTER SET utf8 COLLATE utf8_bin NOT NULL
web-project
QUOTE (IPSATS @ Feb 1 2008, 12:35 PM) *
You need to change the structure of the table for 'categories_name'
there is the SQL command, you need to use wink.gif

ALTER TABLE `categories_description` CHANGE `categories_name` `categories_name` VARCHAR( 64 ) CHARACTER SET utf8 COLLATE utf8_bin NOT NULL


or simply change the size of the field to VARCHAR( 255 )
dfgdhn
to solve this issue for all database (there a lot of varchar, text, tinytext columns smile.gif ) - you can make this step -

1) export sql including create statements from your database to text file
2) at this text file change your codepage for all tables to utf8
3) import text fiel back to database

for example you can use simple phpmyadmin for this operation smile.gif


the same solution can be for cre loaded when you will want change it to cyrillic
ri.noceros
QUOTE (dfgdhn @ Feb 4 2008, 05:27 AM) *
to solve this issue for all database (there a lot of varchar, text, tinytext columns smile.gif ) - you can make this step -

1) export sql including create statements from your database to text file
2) at this text file change your codepage for all tables to utf8
3) import text fiel back to database

for example you can use simple phpmyadmin for this operation smile.gif
the same solution can be for cre loaded when you will want change it to cyrillic


Hello,

I only dont`t understand point "2)"

I already have the exported textfile.
How can I change now to cyrillic - (windows - 1251)? I´ve no clue, which entries I shall find.

In my case cyrillic characters are displayed but some are always missing (f.e. only "рубл" instead of "рубль")

the exported sql from the database for categories looks like that:

DROP TABLE IF EXISTS `categories`;
CREATE TABLE `categories` (
`categories_id` int(11) NOT NULL auto_increment,
`categories_image` varchar(64) default NULL,
`parent_id` int(11) NOT NULL default '0',
`sort_order` int(3) default NULL,
`date_added` datetime default NULL,
`last_modified` datetime default NULL,
PRIMARY KEY (`categories_id`),
KEY `idx_categories_parent_id` (`parent_id`)
) TYPE=MyISAM AUTO_INCREMENT=23 ;

#
# Daten für Tabelle `categories`
#

INSERT INTO `categories` VALUES (22, '', 0, 0, '2008-02-04 14:12:50', NULL);

could you give me a hint, what exactly i would have to change in order to display the cyrillic characters fully right?

thanks to anyone who can give me a tip!
ri.noceros
add > problem with display of cyrillic database-entries ---> f.e. categories -

DROP TABLE IF EXISTS `categories_description`;
CREATE TABLE `categories_description` (
`categories_id` int(11) NOT NULL default '0',
`language_id` int(11) NOT NULL default '1',
`categories_name` varchar(32) NOT NULL default '',
PRIMARY KEY (`categories_id`,`language_id`),
KEY `idx_categories_name` (`categories_name`)
) TYPE=MyISAM;

#
# Daten für Tabelle `categories_description`
#

INSERT INTO `categories_description` VALUES (21, 4, 'Kategorie1');
INSERT INTO `categories_description` VALUES (22, 2, 'dfgdfgd');
INSERT INTO `categories_description` VALUES (21, 1, 'Category1');
INSERT INTO `categories_description` VALUES (21, 2, 'Kategorie1');
INSERT INTO `categories_description` VALUES (22, 4, 'рубл');
INSERT INTO `categories_description` VALUES (22, 1, 'etet');
ri.noceros
hello,

the solution for this tiny little problem was to manually change the entries in the database (varchar 32 to varchar 255, like also described in another post here) in this context it´s also understandable, how this could be done with the exported sql - textfile. sorry, for bothering and thanks for the posts, which lead to the solution. would never solve it without them.
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.
Invision Power Board © 2001-2008 Invision Power Services, Inc.