I know the following is possible in Apex, but I'm wondering whether there's a way to do it with standard formula fields.

Is there a way to split up a value and wrap each bit in other text values? For example (not a real example:

Custom_Field_1 = 'This;That;Other;', but could have any number of terms.

Formula for Custom_Field_2 should wrap each term delimited by ; in <p></p> and remove the ; to result in <p>This</p><p>That</p><p>Other</p>.

  • Is this for the missing feature of frequency reporting for Multi Select Picklists by any chance? Using this formula, or something like it, may make it easier to export to excel and do pivot tables to do the reporting. – JodieM Aug 10 '12 at 9:25
  • @David great edit – Benj Aug 10 '12 at 18:51

A basic solution for the formula would be

'<p>' &  SUBSTITUTE(Custom_Field_1, ';', '</p><p>')   & '</p>'

You can add logic to test if Custom_Field_1 is blank and leave the formula field blank in that instance too if necessary.

| improve this answer | |
  • Clever work-around! – Benj Aug 10 '12 at 16:09

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.