Question

Dependency on 3 lookups with repeated values

Hi community,

if I want to create dependencies on 3 lookups which all have repeated values, how is the logic and process of creating it?

 

For example:

You select "a" in lookup 1, then this gives you 3 values in lookup 2 (which are repeated in other tipologies of lookup 1), and if u select 1 of those values, it gives you a value in lookup 3 which may also be repeated from selecting other tipologies in lookup 2.

 

I have tried to import everything in lookup 3 (with the dependencies of lookup 1 and 2), create the business rules of agregating filtres, and then do the same in lookup 2 with the dependency of lookup 1, with its business rule.

 

It is difficult to explain, but I would appreciate any help.

Thank you!

Regards.

Like 0

Like

2 comments

Hello Francisco,

 

So the simplest example of a similar logic would be Country->State/province(Region)->City

 

At first we choose a country.

 

Then we need to choose a region out of all the regions of the chosen country. So our field to filter would be State/province and the connection field is Country. Field to filter by - Country. The Region table has a CountryId column which refers to the Id column of the Country table.

After that we need to choose a city out of all the cities of the chosen region. So our field to filter would be City and the connection field is State/province. Field to filter by - State/province. The City table has a RegionId column which refers to the Id column of the Region table.

 

 

This is how the filters are set up.

 

To sum up, you need 3 lookups and each lookup must contain objects, for example A, B, C.

B should have a column AId, C should have a column BId.

 

If you are trying to do this with all 3 lookups containing the same objects, I would suggest something like this:

 

Let's say we have an object City. It has the columns id, country_capital_id, state_capital_id. So there are the country capitals, the state capitals and just cities. The country capital is also the capital of its state. 

Now, to connect them we use the same method as above. 

 

Firstly, we choose the Country capital city.

 

Then we need to choose a State capital city out of all the state capital cities of the chosen country capital city. So our field to filter would be State capital and the connection field is Country capital. Field to filter by - Country capital.

 

After that we need to choose a city out of all the cities of the chosen state capital cities. So our field to filter would be City and the connection field is State capital. Field to filter by - State capital. 

 

I hope this helps you!

 

Best regards,

Max.

Really appreciate the response Max! Thank you!

 

Best regards.

Show all comments