Getting foreign key from related table?
I have 3 tables:
I have a Clients layout for entering clients, a Loans layout for entering loans, and a Payments layout for displaying payments.
I have entered a client on the client layout and have a button to Add / Edit loans. It takes you to the Loans layout so you can enter the parameters for the loan. There are no client fields on the layout. When I add a loan, the _kf_clients_id is empty.
Obviously, I want it to pull the _kp_clients_id from the clients table when a record is added to the loans table.
The tables are related as follows:
Client to Loans - _kp_client_id -> _kf_client_id
Loans to Payments - _kp_loans_id -> _kf_loans_id
I tried putting a "calculated value" in the _kf_client_id field in the loans table by simply specifying the _kp_client_id field in the clients table, but that didn't work.
I tried putting in a lookup value in the loans _kf_client_id field, but I figured that wouldn't work because it's empty when the record is created.
Can someone put me in the right direction.
Incidentally, I don't want a portal on the Client's layout due to space limitations.