your calculation works ONLY and ALWAYS evaluating the first related record so, if the first related record isn't empty, the returned result is right.
If the first related record is not empty, I want it to say "Austenitized at" but it keeps saying "Tempered at". The corresponding field in the first related record is not empty in this case.
Did I write the calculation backwards?
The case statement's syntax appears correct. If you place a unsorted portal to Heat Treatment 2 on your layout (just as a way to check things), do you see the record you expect in the first row of your portal?
As Raybaudi has indicated, this calculation will ignore all but the first related record. So you may need to doublecheck that your relationship is matching to the records you expect.
Wow, I'm glad you asked me to do that because the issue appears to be completely different from what I thought it was. When I open up an unsorted portal, nothing actually comes up. I checked in the reltionship table and everything looks good. I have one field that contains one non-duplicated code of the same value connected in both databases.
So then I tried to just make a field that contained a lookup value from the heat treatment 2 database. When I typed in the corresponding code into my original database the lookup also did not work...............
As I was typing this I found the issue....I had made my relationship between databases by adding a database non-remotely. I redid everything, added the heat treatment 2 database remotely and this all worked fine.
Thanks so much for your help.