Jump to content
View in the app

A better way to browse. Learn more.

FMForums.com

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Multiple codes, multiple results, 2 fields total??

Featured Replies

  • Author

Sorry---don't know too much. I have a field called "code" that could have 1, 2, 3, or more codes, separated by a double quote (I don't have a choice). Example, code = AA, or AA"BB"CC. I want a calculation to look at "code", and put the results in a field called "display." There could be 1 result, or 3, or 10. By using a Case statement with PatternCount for each code and it's result, I got it working but it only spits out the first result. How do I make it look at all the codes in the "code" field and spit out ALL of the results in the "display" field (separated by a line break, comma, whatever). ::? THANKS!

Sorry---don't know too much. I have a field called "code" that could have 1, 2, 3, or more codes, separated by a double quote (I don't have a choice). Example, code = AA, or AA"BB"CC. I want a calculation to look at "code", and put the results in a field called "display." There could be 1 result, or 3, or 10. By using a Case statement with PatternCount for each code and it's result, I got it working but it only spits out the first result. How do I make it look at all the codes in the "code" field and spit out ALL of the results in the "display" field (separated by a line break, comma, whatever). :?: THANKS!

  • Author

Sorry---don't know too much. I have a field called "code" that could have 1, 2, 3, or more codes, separated by a double quote (I don't have a choice). Example, code = AA, or AA"BB"CC. I want a calculation to look at "code", and put the results in a field called "display." There could be 1 result, or 3, or 10. By using a Case statement with PatternCount for each code and it's result, I got it working but it only spits out the first result. How do I make it look at all the codes in the "code" field and spit out ALL of the results in the "display" field (separated by a line break, comma, whatever). :?: THANKS!

To rephrase, all you want is to essentially replace the double quotes with a comma, blank, or tab?

Use the Substitute() function. Bang. You're done.

If you need to process these 'codes' further, then pop them out into repeating fields... but you do have to learn how to properly use repeats. If you're just starting with FM, you might want to wait a few weeks to get more of the basics solidly under your belt.

To rephrase, all you want is to essentially replace the double quotes with a comma, blank, or tab?

Use the Substitute() function. Bang. You're done.

If you need to process these 'codes' further, then pop them out into repeating fields... but you do have to learn how to properly use repeats. If you're just starting with FM, you might want to wait a few weeks to get more of the basics solidly under your belt.

To rephrase, all you want is to essentially replace the double quotes with a comma, blank, or tab?

Use the Substitute() function. Bang. You're done.

If you need to process these 'codes' further, then pop them out into repeating fields... but you do have to learn how to properly use repeats. If you're just starting with FM, you might want to wait a few weeks to get more of the basics solidly under your belt.

  • Author

To rephrase, all you want is to essentially replace the double quotes with a comma, blank, or tab?

Use the Substitute() function. Bang. You're done.

If you need to process these 'codes' further, then pop them out into repeating fields... but you do have to learn how to properly use repeats. If you're just starting with FM, you might want to wait a few weeks to get more of the basics solidly under your belt.

No, I don't need to substitute. I need the calculation to look at the code(s) that are in "code" field and put the result(s) in the "result" field. Thanks!

  • Author

To rephrase, all you want is to essentially replace the double quotes with a comma, blank, or tab?

Use the Substitute() function. Bang. You're done.

If you need to process these 'codes' further, then pop them out into repeating fields... but you do have to learn how to properly use repeats. If you're just starting with FM, you might want to wait a few weeks to get more of the basics solidly under your belt.

No, I don't need to substitute. I need the calculation to look at the code(s) that are in "code" field and put the result(s) in the "result" field. Thanks!

  • Author

To rephrase, all you want is to essentially replace the double quotes with a comma, blank, or tab?

Use the Substitute() function. Bang. You're done.

If you need to process these 'codes' further, then pop them out into repeating fields... but you do have to learn how to properly use repeats. If you're just starting with FM, you might want to wait a few weeks to get more of the basics solidly under your belt.

No, I don't need to substitute. I need the calculation to look at the code(s) that are in "code" field and put the result(s) in the "result" field. Thanks!

Are you trying to generate the results into seperate entries for the "display" field, or a repeating field? If not, and the results are generated into a single corresponding "display" field with the values only delineated by a comma or other charcter, why not use a substitute?

I'm not sure exactly what you are trying to accomplish.

Example, code = AA, or AA"BB"CC

display= AA,BB,CC

or are you trying to get 3 seperate records of display / repeating field

AA

BB

CC

Are you trying to generate the results into seperate entries for the "display" field, or a repeating field? If not, and the results are generated into a single corresponding "display" field with the values only delineated by a comma or other charcter, why not use a substitute?

I'm not sure exactly what you are trying to accomplish.

Example, code = AA, or AA"BB"CC

display= AA,BB,CC

or are you trying to get 3 seperate records of display / repeating field

AA

BB

CC

Are you trying to generate the results into seperate entries for the "display" field, or a repeating field? If not, and the results are generated into a single corresponding "display" field with the values only delineated by a comma or other charcter, why not use a substitute?

I'm not sure exactly what you are trying to accomplish.

Example, code = AA, or AA"BB"CC

display= AA,BB,CC

or are you trying to get 3 seperate records of display / repeating field

AA

BB

CC

  • Author

Are you trying to generate the results into seperate entries for the "display" field, or a repeating field? If not, and the results are generated into a single corresponding "display" field with the values only delineated by a comma or other charcter, why not use a substitute?

I'm not sure exactly what you are trying to accomplish.

Example, code = AA, or AA"BB"CC

display= AA,BB,CC

or are you trying to get 3 seperate records of display / repeating field

AA

BB

CC

I am trying to get the result(s) into 1 repeating field

Example 1, code = AA"BB"CC

display= Apple Aaron; Bob Boy; Cory Cody

Example 2, code = AA

display = Apple Aaron

Thanks!

  • Author

Are you trying to generate the results into seperate entries for the "display" field, or a repeating field? If not, and the results are generated into a single corresponding "display" field with the values only delineated by a comma or other charcter, why not use a substitute?

I'm not sure exactly what you are trying to accomplish.

Example, code = AA, or AA"BB"CC

display= AA,BB,CC

or are you trying to get 3 seperate records of display / repeating field

AA

BB

CC

I am trying to get the result(s) into 1 repeating field

Example 1, code = AA"BB"CC

display= Apple Aaron; Bob Boy; Cory Cody

Example 2, code = AA

display = Apple Aaron

Thanks!

  • Author

Are you trying to generate the results into seperate entries for the "display" field, or a repeating field? If not, and the results are generated into a single corresponding "display" field with the values only delineated by a comma or other charcter, why not use a substitute?

I'm not sure exactly what you are trying to accomplish.

Example, code = AA, or AA"BB"CC

display= AA,BB,CC

or are you trying to get 3 seperate records of display / repeating field

AA

BB

CC

I am trying to get the result(s) into 1 repeating field

Example 1, code = AA"BB"CC

display= Apple Aaron; Bob Boy; Cory Cody

Example 2, code = AA

display = Apple Aaron

Thanks!

  • Author

Anyone??? Help would be MUCH appreciated!!!

  • Author

Anyone??? Help would be MUCH appreciated!!!

  • Author

Anyone??? Help would be MUCH appreciated!!!

By using a Case statement with PatternCount for each code and it's result, I got it working but it only spits out the first result

Your solution seems nearly correct to me, but use a concatenation of If or Cases and not a single Case statement.

If( PatternCount(qq; x); "J.Ickx;"; "") &

If( PatternCount(qq; y); "I.Grec;"; "") &

...

The final ";" is a problem but can also be solved with some inspiration

By using a Case statement with PatternCount for each code and it's result, I got it working but it only spits out the first result

Your solution seems nearly correct to me, but use a concatenation of If or Cases and not a single Case statement.

If( PatternCount(qq; x); "J.Ickx;"; "") &

If( PatternCount(qq; y); "I.Grec;"; "") &

...

The final ";" is a problem but can also be solved with some inspiration

By using a Case statement with PatternCount for each code and it's result, I got it working but it only spits out the first result

Your solution seems nearly correct to me, but use a concatenation of If or Cases and not a single Case statement.

If( PatternCount(qq; x); "J.Ickx;"; "") &

If( PatternCount(qq; y); "I.Grec;"; "") &

...

The final ";" is a problem but can also be solved with some inspiration

Create an account or sign in to comment

Important Information

By using this site, you agree to our Terms of Use.

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.