AnsweredAssumed Answered

How to look up value from a field in another table if record contains a certain value in another field

Question asked by schpa on Jan 15, 2015
Latest reply on Jan 15, 2015 by jbrown

Hey!

 

So I'm trying to make a calculated value that automatic fills a field in a layout "Orders" from a field in a related table "Partners" if the record is marked as the standard partner.

 

 

 

The way I've selected if the actual partner is the standard partner for the related firm is by a field called "Standard" with two values: "Yes" or "No"
Only one partner per firm will be marked as "Standardpartner" for the selected firm and this is the partnerinfo I want automatic to be filled in as the reference partner for the order, but that later on can be changed if desired, therefore making the field an automatic look-ed up value field that can be changed by the user.

 

Now, I've tried all kinds of different calculations that decides that it will import the partner data IF the partner is marked as "Yes" under the "Standard" field in their respective records located in the "Partner" table, if this makes sense.


One of the calculations looks like this:
( If ( Partner::Standard = "Yes" ; Partner::Name ; "" ) & Get ( ActiveFieldContents )

 

 

 

This obviously does not work as intented as it either will not import anything, or just import the first related partner data to the firm selected in the order layout.

 

Any ideas to on how to make this work? I've tried searching all over for a similar request but I couldn't find it =/

 

Thanks in advance!

 

Simen

Outcomes