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.

Featured Replies

Hi all

I'm trying to display a list inside one field on one row that contains the field values of the related child records. Using UniqueValues() I'm able to filter that list down to remove duplicates, of which there are many for some records. The following calculation works as expected, however UniqueValues() seems to be counting an extra blank record at the end and I'm struggling to find how this is happening.

I'm using Substitute() to replace carriage returns with a comma to keep the data on one line. If left as a list there is a blank row at the bottom of the field. When subbing returns for commas the last returned item is followed by a comma.  See below:

Substitute ( UniqueValues ( List ( Product Assets::ownership ) ) ; "¶" ; ", " )

 

Record One
Record Two
Record Three

 

Record One, Record Two, Record Three,

Perhaps there's another way to achieve this, and/or I'm missing something simple. Suggestions appreciated!

 

Edit: Ok, after further reading I realize this is normal behavior.

Edited by madman411

All xValues functions include a trailing carriage return in their result. In your example, you could do:

Substitute ( UniqueValues ( List ( ChildTable::Valuefield ) ) & ¶ ; [ "¶¶" ; "" ] ; [ ¶ ; ", " ] )

 

  • Author
5 minutes ago, comment said:

All xValues functions include a trailing carriage return in their result. In your example, you could do:


Substitute ( UniqueValues ( List ( ChildTable::Valuefield ) ) & ¶ ; [ "¶¶" ; "" ] ; [ ¶ ; ", " ] )

 

Thanks comment - of course this worked. You're a star. Can you explain what is happening in this function so I can better understand? Cheers

First we append another CR to the result of UniqueValues(), so we get:

"Record One¶Record Two¶Record Three¶¶"

Now we substitute (1) a pair of CRs with nothing:

"Record One¶Record Two¶Record Three"

and (2) a CR with comma and space:

"Record One, Record Two, Record Three"

 

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.