Why I cannot put a Vietnamese name in unicode for label of Product fields
Hi guys,
I cannot put a Vietnamese name in unicode for label of Product fields, in backend, when I add a field I cannot choose DBType to NVARCHAR, just VARCHAR so I cannot store label name of this field in Vietnamese, in front end site, it is display incorrectly. Exp: you can try with this words "Tiếng Việt".
Please, fix error.
Hi Thanh,
I tested the scenario you describe and the string in question was persisted as a VarChar. If you require specific NVarChar entries, you can change the database type of your field via code. The following is an example:
var metaManager = MetadataManager.GetManager();
var theField = metaManager.GetMetafields().Where(f => f.Title ==
"YourProductTypeField"
).FirstOrDefault();
theField.DBType =
"NVARCHAR"
;
metaManager.SaveChanges();
Thanks, it's helpful.
Hi Ivan,
Can we have a way to solve it without coding, because I just want to add its from backend module, I cannot code for every single field, the simplest way is change DBTYPE of [sf_meta_fields.title_] to NVARCHAR, can I do it at the application starts?
Hello Thanh,
If you do not want to use any code, there is a setting available for this functionality. Go to Administration->Settings->Advanced->Metadata->Database Mappings. Locate the control which you want to map in a different manner and change its DataType and SQL specific type accordingly. You will need to restart the application in order for the changes to apply.
Regards,
Ivan D. Dimitrov
Telerik