1 Reply Latest reply on Nov 28, 2015 2:51 PM by TorstenBernhard

A newbie need a little help - Calculation for wedding guest name & Plus1

So first i want to say thank you for all of the help that I'm hopefully going to get for this

so basically what I'm trying to is link two names in calculation (two calculation fields)

So basicly I'm looking to do is if they have a plus one and i know there name i want to be able to address the everything with Mr John Doe  and Mrs Jane Doe

Here are the field names I'm using

Wedding guest = C_Guest Fullname

Wedding guests plusone (which is in a different table) = WeddingGuestPlusone::C_plusoneFullname

Also while I'm here ill also ask this to, now if my soon to be wife wants to have it look something like Mr & Mrs Doe how would i do that in a calculation

Thank you again and I'm going to guess that this is an easy thing to do but I'm extremely green (NEW) to file maker this my second database

Thanks

Joe

• 1. Re: A newbie need a little help - Calculation for wedding guest name & Plus1

In principle, Names and other personal data are of identical types for Guest and PlusOne. They can be kept in one table 'Guest'.

Add a field ID_ Guest (number, auto-increment) and a field ID_PlusOne (number).

Enter data in the guest list is then done in a single layout for a single table.

For attributing a PlusOne to a Guest, create a copy of the Guest table TOC and name it PlusOne. Connect the two through a relationship

Guest::ID_Guest = PlusOne::ID_PlusOne.

Now you have a relationship that links a PlusOne to a Guest through these fields.

For attributing a PlusOne to a Guest, create a Portal on your layout (based on the PlusOne TOC) that lets you select a person (represented by a portal row). Place a button for a script in the portal row.

The script

- gets the main list record's ID_Guest and stores it in a variable (\$ID)

- and writes the content of \$ID in the selected portal row's ID_PlusOne field

Now you have a relationship between a Guest and a PlusOne

Of course, nothing forbids doing the same with two tables Guest and PlusOne.

Happy coding!