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.

Value list depend on relationship !

Featured Replies

Hi All,

I plan to make a value list depend on relationship but it gives me 2 choices to search for value list. Let's me clear it out.

I have State and city

MA Boston

If people type only MA , it shows up MA and all cities in MA and correspondent information , but if they type MA and Boston , it shows only MA and Boston city and correspondent information. With my knowledge, value list depends only one relationship, it does not base on 2 relationships. Anyone has that problem before?

Thanks

Anh Tran

Make a calc field State & City and use them on both sides of the relationship

  • Author

Hello Pupiweb,

if make calc field State & City on both side, it means it works if they enter both State & City, but if they only enter State and not enter City, it will not work because one side have State and other side have State & City. Do I miss something basic here??

Anh Tran

  • 2 weeks later...
  • Author

hi all there,

I would like to know if someone can help me with this problem above? I try to pull out the value list depend on two relationship but FM can give me one choice of one relationship.

Any help would be appreciated.

Thanks

Anh Tran

Left side : State & " " & City

Right side ??? State&"[par]"&City& "[par]"&State & " " & City

  • Author

Ugo what is par.gif means???

Anh Tran

  • Author

oh it means returns key???

Thanks

Anh Tran

  • Author

Hello Ugo,

It works fine even I don't understand why the par.gif makes it work.

Thanks

Anh Tran

Hi,

The carriage return create a new index, so you now have 3 sets of index to match the left side of relationship.

Have a look at some threads about Multi-key, or just have a try with a checkbox text field. Each values in the checkbox field (apart globals) are indexed.

  • Author

Hello

Thanks Hugo, I got your point.

Anh Tran

  • Author

Hello Ugo,

can it be done if the value list depend on relationship and include some value. It means depend on the value you got a list and some name you want to see on the list. It is like when I type Ma Boston , i want to see information about Ma and Boston and Ameria , When I type CA Lasvegas, I want to see the list include CA Lasvegas and Ameria ... Can it be done? ...

Thanks

Anh Tran

Hi,

Not sure I fully understood what you were looking for.What kind of relationship is there from MA Boston and Ameria ?

If you want a third (related value) to be added to the left key, then you'll have to deal with an additional calculation, and use it for this left key.

Now, the whole calc and settings would change wether :

- There is only one related records (Ameria)

- There are Many related records (Ameria,...)

- The related record is related to City, to State or to the Candidate Key City & " " &State.

Supposing the first solution, your calc would simply be

c_NewLeftKey = City&" "&State & "Paragraph"& ::related record.

For the second solution, you would need an additional calculation c_VRelList = ValueListItems(Status(CurrentFileName), "related value list") and your calc for left key would be

c_NewLeftKey2 = City&" "&State& "Paragraph"& ::related record.

Last, if you wanted a list to become

MA Boston Related Value 1

MA Boston Related Value 2

MA Boston Related Value 3

....

Then, you'll change the c_LeftKey calc to :

c_LeftKeyNew3 = Substitute(c_VRelList ,"Paragraph", City&" "&State&"Paragraph")

Hope my guess were good.

can it be done if the value list depend on relationship and include some value. It means depend on the value you got a list and some name you want to see on the list. It is like when I type Ma Boston , i want to see information about Ma and Boston and Ameria , When I type CA Lasvegas, I want to see the list include CA Lasvegas and Ameria ... Can it be done? ...

Thanks

  • Author

hihihi Hello Ugo ...

I think your guess is wrong this time smile.gif))) ...what I want to do is exact the above answer that you gave ...with addition is that I want the value list depend on relationship but in the value list include some constant names. Forexample , whenever the relationship is set ...the constant name is "America" is always included in value list.

Do you get me this time ...I think I found the way to do it. I enter manually the leftkey : State & City & par.gif &

"America" so that America appears alway in the value list.

Thanks

AnhTran

AMERICA!!!!

Well, yes apart that America won't appear in your value list. It would be set in a calcultation for your left key.

Your value list would display State & City

Your calc field would display State & City & " par.gif" & "AMERICA"

  • Author

hihihi

Ugo,

you are right ...

Thanks

Anh Tran

Create an account or sign in to comment

Important Information

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

Account

Navigation

Search

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.