# Look up values based on two fields

## Recommended Posts

I want to create a formula that takes information from 2 fields and displays the answer in a 3rd for example

if field A is 10 and field B is 10 display A in the 3rd field

thanks

##### Share on other sites
17 minutes ago, Adam Masters said:

if field A is 10 and field B is 10 display A in the 3rd field

I am afraid the logic of your example escapes me. And what does this have to with Server Administration?

##### Share on other sites

is this not a file maker forum

##### Share on other sites

FieldC:

` Case ( FieldA = FieldB ; "A" ; "B" ) `

This will display "A" in field C if the two fields are equal but if you have more logic such as ranges or > or < that may take a bit further explanation of what your after...

(PS moved topic to this forum)

also this is a good read https://fmforums.com/guidelines/

##### Share on other sites

Thank you

I have looked at that but what I want to do is

Field A = 10 and B = 10 Display A

but then

if A=20 B=20 display B

and A=30 B=20 Display C

and so on

thanks

##### Share on other sites

Instead of (or in addition to) giving examples, explain the rule that needs to applied here. I, for one, cannot see the logic that would explain the results you show.

##### Share on other sites
 Field A Field B Field C 10 10 A 20 20 B 30 20 ?

I am not seeing a progression that can be handled by math to arrive at result.

More detail is needed.

##### Share on other sites

there is a table I am working off so field c will have to be data that I enter

##### Share on other sites

ok read the sheet you sent me so will try and explain a bit better I would like to enter a number value in field a and a number value in field B then pending on the answer a predetermined letter will be shown in field C

Field A number from drop down list

Field B number from drop down list

Field C will take the results for fields A and B the display a letter which is predetermined for the result

##### Share on other sites

In this case if you have a table of A & B and C and all the logic is arbitrary then as users select A & B the value C would be looked up or auto enter calc - no math.

you would related this library table with multi predicates on Field A & Field B.

Sample file.

##### Share on other sites
• Ocean West changed the title to Look up values based on two fields

I've got that I should be able to work the rest out

## Create an account or sign in to comment

You need to be a member in order to leave a comment

## Create an account

Sign up for a new account in our community. It's easy!

Register a new account