1

I want to import french customers. In french we say Chère for women, Cher for men instead of misses and mister.

but it is not possible to import the contacts and choose theese salutations. Always the error that the salutation is unknonw:"Invalid value for field(s) : La salutation par courriel doit etre l'une des salutations pre-configurees."

In civi there is the french salutation and as default.

Do you have a solutions for that? Thanks

1

I think it should be possible to import prefixes (such as Madame or Monsieur) but you need to make sure that the prefixes are created in CiviCRM before you import the data (/civicrm/admin/options/individual_prefix?reset=1).

Also, the Labels in CiviCRM need to be exactly as those in the column of your import file.

Or do you want to import greetings (email or postal greetings)? I am not sure, if this is possible because they are usually generated.

You could try to use something like this for generating a greeting depending on the prefix (just enter it here: /civicrm/admin/options/email_greeting?reset=1):

{capture assign=c}{contact.communication_style}{/capture}{capture assign=p}{contact.individual_prefix}{/capture}{if $p=="Madame"}Chère{else}Cher{/if}{ }{if $c=="Familiar"}{ }{contact.first_name}{else}{$p}{ }{contact.formal_title}{contact.last_name}{/if}

CiviCRM would the create an appropriate greeting depending on the communication style (formal or familiar) and the prefix. Please note that for this approach you need to have smarty enabled.

| improve this answer | |
  • thanx fabian. yes I want to have the correct email and postal greetings after have imported the contacts. How does civi generate the greetings? This would be awesome for me if this works. here: /civicrm/admin/options/email_greeting?reset=1) I have the correct greetings. – Oliver Feb 20 '16 at 18:11
  • Yes, you have to enter the syntax from my answer above (or similar) as postal and email greetings and set it as default. You need to have smarty enabled (see wiki: wiki.civicrm.org/confluence/display/CRMDOC/…) – Fabian Feb 22 '16 at 8:23
  • I got it. wonderful. thx. I come more into it :) now it makes madame = Chére, and the rest = cher, this means Mister = Cher. It makes no difference between the languages. Is it possible to distinguish the language? Madame = Chére Monsieur = Cher Frau = Sehr geehrte Herr = Sehr geehrter – Oliver Feb 24 '16 at 17:04
  • It is possible to extend the smarty logic that way. But the approach is somewhat limited because the greeting fields have a maximum length and thus to not support too complex logic. – Fabian Feb 25 '16 at 13:05

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.