How to translate field values? - Answers - Salesforce Trailblazer Community
Trailblazer Community
Ask Search:
Adam CooperAdam Cooper 

How to translate field values?

Here is the senario:

We have pieces of equipment (e.g. vending machines and coolers) that we need to track and perform service on. Equipments have certian "classifications" that can change, such as the way the door opens (left, right, top...) or the capacity of the equipment (100, 200, 300 cans etc.). There can be any number of classifications for different types of equipment. 

We have tackled this so far by creating a custom object called "Equipment Characteristics" which has three fields: Characteristic Name (e.g. door type), Characteristic description (e.g. right door) and Characteristic value (e.g. RD which is the value stored in our ERP system and what we need to send back via integration to update the equipment record there also). 

So the challenge is how can we translate the actual values such as "right door" into different languages for our different territories? We can translate the field labels no problem, but how do we translate the actual field value? We didn't want to use picklists for this because we were told these couldn't be updated via integration (which is required because these classifications come from our ERP system which can update the custom object) 

And any better solutions on how to store these equipment characteristics is more than welcome too :)

Thanks! 

Adam. 
Laura BellLaura Bell
There isn't anything native to Salesforce that would translate the data entered into a field.
The translation workbench allows you to translate custom objects and fields and picklist values.

You would need to create a record for each language. Then what I would do is add a picklist value to identify the language for the given record. Then I would make the custom object private and then using criteria based sharing rules open access to the records based on roles or groups. So all Spanish users can only see Spanish records only and all English users see English records only.
Adam CooperAdam Cooper
Hi Laura,

Thank you for your suggestion!

However we may have two users logged in at the same time in different languages looking at the same equipment object. We would want them to see a different value in the field depending on what language they are logged in as. If they were choosing the value of the field i think that would work, but then if another user in a different language logged in, wouldnt they see the wrong language, or a blank value because that object is private?

Adam.
Ann Manza-GeertsAnn Manza-Geerts
Hi Adam,

Picklist values can be updated via integration with your ERP system, however - if the values in your ERP system are free text and can be in multiple languages, salesforce.com will need to mimic this behaviour (and will need free text that can be in different languages).

If in your ERP system that underlying values are numbered e.g. "1" means "right door", you should work with picklist values, and use the translation workbench to translate 1 into "right door", "porte droite" etc...

I hope this helps!

Good luck,

Ann Manza
Adam CooperAdam Cooper
Hi Ann,

Many thanks for your reply!

Could you elaborate on how we can update pick lists via integration?

In our ERP, they are stored as values, such as RD=Right Door in English. So I think we could do what you say and use the translation workbench. But this would need to be manual and we couldn't do this via integration?

Ta,

Adam.
Ann Manza-GeertsAnn Manza-Geerts
Hi Adam,

The value on a record can be updated easily like the value on any other field type.

So...it can't be that easy and I must have misread your question? Maybe you want to add, remove or replace picklist value on the field itself - not simply on a given record in your database, right? That is indeed not possible, but maybe not needed?
It is possible in salesforce.com to update the value on a record in a picklist field, even if that value had not been defined on that field in setup - and you can add values later on manually.


How is the data stored in your ERP? Text? Numbers? Is it a different table containing a unique id + text in different languages? I'd need to dive into your functional requirements to better understand what it is your are trying to achieve and how often values change in your ERP...but another option would also be to build a new table that contains those same values as the back-end system you are integrating with.
Laura BellLaura Bell
If the information which you are importing is a list of known information and can be built as picklist fields that you can utilize the translation workbench to create translations in different languages.

For example: if the value is RD coming from ERP, then you would map that to a picklist field where RD = Right Door in the picklist value.  Then in the translation workbench, you would translate it to the languauges that you need. So if the user has their languauge set to spanish, they would see the puerta a la derecha or whatever you put in the translated workbench.

The workbench would only work if you had picklist fields and not text fields.
Adam CooperAdam Cooper
Hi Laura and Ann, again thank you for your replies!

We are trying to maintain a list of allowed values in SalesForce that a user can pick from. But these values must be what is in our ERP which is the need to send them from ERP --> SF.

In the ERP they are stored as Characteristic - Value - Description where description can be different in each language. In an ideal world, we would want whatever is in the ERP to be the same in SF but not sure this is going to be possible.

e.g.

Characteristic = Door type
Value = RD
Description = Right door (or porte à droite in French, or xxx xxxx in Dutch)

New Characteristics and values may be added on a monthly basis and translations may be changed every few months (due to them being not quite right first time round).

Based on your answers I have built two custom objects:

Equipment characteristics

- Name

Equipment characteristic values

- Characteristic (master detail relationship back to the equipment characteristics object­)

- Value

- Description

On the Equipment object, I have added a field for each characteristic that is a lookup to the "Equipment characteristic values" object and applies a filter to only show results for the equipment characteristic that field is designated to store. This works quite well apart from the fact you can't automatically list all values in a lookup dialog and the user has to search with two characters to find anything.

However, if someone logs in using the French language, everything here will be in English apart from the custom field I added to the equipment which I can translate. I don't see a way to translate the actual records of the object I'm looking up? E.g. from equipment I look up a characteristic value, it will show in English because it's stored in the Equipment characteristic values table as English.

Hopefully that makes a little sense!

Thanks again,

Adam.
Ann Manza-GeertsAnn Manza-Geerts
Hi Adam,

I think what you made makes sense, and is in the long run the most durable
option.

A couple of alternatives or ad'l developments that may help:
- use a visualforce component to replace the current lookup by a picklist
so that users do have a picklist at their disposal - but problem of the
translation would remain

- use a visualforce component and using apex, visualise to the user
only the descriptions in his/her language (based on the language setting of
the user profile) - this assume that the descriptions in each language have
some indication of the language they are in - as you don't mention this,
this may not be the case


-(but this is maintenance intensive) instead of using a custom object, go
back to a picklist field. The values in this picklistfield would contain
only the value (e.g. RD - assuming this one is unique). The actual
descriptions could be translated using the translation workbench. In this
setup your picklist would contain only "values" but the descriptions that
have been translated in the translation workbench would be what a user
actually sees and should pick from the drop-down list.
The characteristic "Door Type" could be filled in using dependent picklist
fields or formula fields.
The disadvantage of this option would be that a manual maintenance of
picklist values will be necessary, whereas in your current setup with
custom objects, you can interface directly with your ERP and have them be
updated automatically.


Hope this helps!

Ann.
Amin MisrieAmin Misrie
Hello Adam,

We have read your concern about this subject and maybe our app can provide you the solution that you are looking for. Now, you can translate all your Salesforce fields from any language, any object and for any operation with Google Translate. We invite you to check it now in Salesforce AppExchange. Link: https://sforce.co/2OtOr2L

You will find the faq and more information in our website http://s4g.es/omnitranslate/. If you have any other questions please contact us through the following email omnitranslate@s4g.es.

Hope you find it interesting! Regards.